In Rails 3, the validators is changed: now is possible to specify all the validators for a specific field in once:
so instead to write
Rails 2.x.x style
validates_size_of :username, :within => 5..15, :message=> "username size must be between 5 and 15"
now I can write
Rails 3 style
validates :username, :length => { :minimum => 5, :maximum => 40 }
But if I add :messge=> "bla bla bla" in this last example (Rails 3 style) an error occur, so the question is: How to edit personal error message to the model in order to show them in the view ?
Thank you