diff options
| author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-01-04 12:26:01 -0300 |
|---|---|---|
| committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2015-01-04 12:26:01 -0300 |
| commit | 6d72485b6977804a872dcfa5d7ade2cec74c768e (patch) | |
| tree | ff4e2cf5ab8a010c00ee46ad8e7d26a479e416b5 /activemodel/lib/active_model | |
| parent | c7a1fa364012c70e76d19b36881c9bde016091b8 (diff) | |
| parent | bf7b8c193ffe2d6a05272a6ed763d87cfe743bb4 (diff) | |
| download | rails-6d72485b6977804a872dcfa5d7ade2cec74c768e.tar.gz rails-6d72485b6977804a872dcfa5d7ade2cec74c768e.tar.bz2 rails-6d72485b6977804a872dcfa5d7ade2cec74c768e.zip | |
Merge pull request #18325 from rafaelfranca/rm-remove-deprecations
Remove all deprecation code
Diffstat (limited to 'activemodel/lib/active_model')
| -rw-r--r-- | activemodel/lib/active_model/dirty.rb | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/activemodel/lib/active_model/dirty.rb b/activemodel/lib/active_model/dirty.rb index 094424e4fd..afba9bab0d 100644 --- a/activemodel/lib/active_model/dirty.rb +++ b/activemodel/lib/active_model/dirty.rb @@ -1,6 +1,5 @@ require 'active_support/hash_with_indifferent_access' require 'active_support/core_ext/object/duplicable' -require 'active_support/core_ext/string/filters' module ActiveModel # == Active \Model \Dirty @@ -116,7 +115,6 @@ module ActiveModel included do attribute_method_suffix '_changed?', '_change', '_will_change!', '_was' - attribute_method_affix prefix: 'reset_', suffix: '!' attribute_method_affix prefix: 'restore_', suffix: '!' end @@ -204,15 +202,6 @@ module ActiveModel @changed_attributes = ActiveSupport::HashWithIndifferentAccess.new end - def reset_changes - ActiveSupport::Deprecation.warn(<<-MSG.squish) - `#reset_changes` is deprecated and will be removed on Rails 5. - Please use `#clear_changes_information` instead. - MSG - - clear_changes_information - end - # Handle <tt>*_change</tt> for +method_missing+. def attribute_change(attr) [changed_attributes[attr], __send__(attr)] if attribute_changed?(attr) @@ -231,16 +220,6 @@ module ActiveModel set_attribute_was(attr, value) end - # Handle <tt>reset_*!</tt> for +method_missing+. - def reset_attribute!(attr) - ActiveSupport::Deprecation.warn(<<-MSG.squish) - `#reset_#{attr}!` is deprecated and will be removed on Rails 5. - Please use `#restore_#{attr}!` instead. - MSG - - restore_attribute!(attr) - end - # Handle <tt>restore_*!</tt> for +method_missing+. def restore_attribute!(attr) if attribute_changed?(attr) |
