Skip to content

Commit

Permalink
Fix example code of EachValidator [ci skip]
Browse files Browse the repository at this point in the history
We have to specify the `:title` option to really use the
`TitleValidator` defined above.
  • Loading branch information
Domon committed Jul 28, 2014
1 parent d94a0fe commit 524f7b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activemodel/lib/active_model/validator.rb
Expand Up @@ -79,7 +79,7 @@ module ActiveModel
# include ActiveModel::Validations
# attr_accessor :title
#
# validates :title, presence: true
# validates :title, presence: true, title: true
# end
#
# It can be useful to access the class that is using that validator when there are prerequisites such
Expand Down

0 comments on commit 524f7b4

Please sign in to comment.