aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2013-12-12 12:05:39 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2013-12-12 12:05:39 -0800
commitab11742448e92923992a979d357261403705234e (patch)
tree395c116756832b03ca3ec5d339f1067943dc0bd6
parent93ee9f0cba607f1050610cddcfa509e5faa7e731 (diff)
parentf65098148337087eb323f0d06ae08e49cf899e6f (diff)
downloadrails-ab11742448e92923992a979d357261403705234e.tar.gz
rails-ab11742448e92923992a979d357261403705234e.tar.bz2
rails-ab11742448e92923992a979d357261403705234e.zip
Merge pull request #13300 from chancancode/add_nodoc_am_dirty_methods
Added :nodoc: for `attribute_changed?` and `attribute_was` [ci skip]
-rw-r--r--activemodel/lib/active_model/dirty.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activemodel/lib/active_model/dirty.rb b/activemodel/lib/active_model/dirty.rb
index c5f1b3f11a..8ccb25c613 100644
--- a/activemodel/lib/active_model/dirty.rb
+++ b/activemodel/lib/active_model/dirty.rb
@@ -149,12 +149,12 @@ module ActiveModel
end
# Handle <tt>*_changed?</tt> for +method_missing+.
- def attribute_changed?(attr)
+ def attribute_changed?(attr) # :nodoc:
changed_attributes.include?(attr)
end
# Handle <tt>*_was</tt> for +method_missing+.
- def attribute_was(attr)
+ def attribute_was(attr) # :nodoc:
attribute_changed?(attr) ? changed_attributes[attr] : __send__(attr)
end