Permalink
Browse files

Missing object for comparison in ActiveModel::EachValidator example c…

…ode.
  • Loading branch information...
1 parent 2856901 commit bee414748c975b2452bcb5025fe191bf4d06a4ca @treybean treybean committed Aug 17, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 activemodel/lib/active_model/validations/validates.rb
View
2 activemodel/lib/active_model/validations/validates.rb
@@ -48,7 +48,7 @@ module ClassMethods
#
# class TitleValidator < ActiveModel::EachValidator
# def validate_each(record, attribute, value)
- # record.errors[attribute] << "must start with 'the'" unless =~ /^the/i
+ # record.errors[attribute] << "must start with 'the'" unless value =~ /^the/i
# end
# end
#

0 comments on commit bee4147

Please sign in to comment.