I have the following code:

validates_format_of :password, :with => /^\w+$/, :message => ‘Password must be alphanumeric’, :on => :save

In order to get that message to display itself, do I have to say
“!” or will “” also require that I validate the
password. The reason I ask, is that I am doing some updating on a “User”
object and instead of notifiying me when that there is a problem, the
action simply does nothing and I am left wondering why the database
wasn’t updated. Thanks for your help,


Are you checking the return code of save?

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs