diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-02-20 20:57:56 -0200 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-02-20 20:58:58 -0200 |
commit | f55bfe726045594c78438841cdccd5843522deab (patch) | |
tree | 30bb111448809e786724bf3397a2c72af3ad9fda /guides | |
parent | 08d9c7532c7081d6b5964b8edf802fab72224cd7 (diff) | |
download | rails-f55bfe726045594c78438841cdccd5843522deab.tar.gz rails-f55bfe726045594c78438841cdccd5843522deab.tar.bz2 rails-f55bfe726045594c78438841cdccd5843522deab.zip |
Change the deprecation messages to show the preferred way to work with
ActiveModel::Errors
Diffstat (limited to 'guides')
-rw-r--r-- | guides/source/active_record_validations.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/guides/source/active_record_validations.md b/guides/source/active_record_validations.md index 31c5b07a05..cd7d349c82 100644 --- a/guides/source/active_record_validations.md +++ b/guides/source/active_record_validations.md @@ -1078,7 +1078,7 @@ Another way to do this is using `[]=` setter ```ruby class Person < ActiveRecord::Base def a_method_used_for_validation_purposes - errors.messages[:name] << "cannot contain the characters !@#%*()_-+=" + errors.messages.add(:name, "cannot contain the characters !@#%*()_-+=") end end |