This project is archived and is in readonly mode.

Changeset [7045c4c279499eb7340fb420398d613497739eef] by José Valim

January 8th, 2010 @ 08:36 PM

Allow validates to map some types to specific options. So now you can do:

validates :email, :presence => true, :format => /@/ validates :genre, :inclusion => %w(m f) validates :password, :length => 6..20 http://github.com/rails/rails/commit/7045c4c279499eb7340fb420398d61...

Committed by José Valim

  • M activemodel/lib/active_model/validations/numericality.rb
  • M activemodel/lib/active_model/validations/validates.rb
  • M activemodel/test/cases/validations/validates_test.rb
  • M activemodel/test/models/person.rb

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>