aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/active_record_validations_callbacks.textile
diff options
context:
space:
mode:
authorElben Shira <elbenshira@gmail.com>2010-12-14 20:35:08 -0600
committerElben Shira <elbenshira@gmail.com>2010-12-14 20:35:08 -0600
commitde4f9acad8b7014b29352a747926ee2db6f71643 (patch)
tree5dc6345cad91e534ceea49950a021f5ca50c1155 /railties/guides/source/active_record_validations_callbacks.textile
parent73dafba6ca484e1772fea8cd25ad27ff65c6c66b (diff)
downloadrails-de4f9acad8b7014b29352a747926ee2db6f71643.tar.gz
rails-de4f9acad8b7014b29352a747926ee2db6f71643.tar.bz2
rails-de4f9acad8b7014b29352a747926ee2db6f71643.zip
It should be ActiveModel::Validator, not ActiveRecord::Validator.
Diffstat (limited to 'railties/guides/source/active_record_validations_callbacks.textile')
-rw-r--r--railties/guides/source/active_record_validations_callbacks.textile2
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/guides/source/active_record_validations_callbacks.textile b/railties/guides/source/active_record_validations_callbacks.textile
index 0824ba450c..a15571fe58 100644
--- a/railties/guides/source/active_record_validations_callbacks.textile
+++ b/railties/guides/source/active_record_validations_callbacks.textile
@@ -414,7 +414,7 @@ class Person < ActiveRecord::Base
validates_with GoodnessValidator
end
-class GoodnessValidator < ActiveRecord::Validator
+class GoodnessValidator < ActiveModel::Validator
def validate
if record.first_name == "Evil"
record.errors[:base] << "This person is evil"