aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2010-03-17 10:04:49 -0700
committerJeremy Kemper <jeremy@bitsweat.net>2010-03-17 10:09:14 -0700
commit843255a763c5e68beaa3a1b0bca306c625c30797 (patch)
tree4eb5f258d9ffde277ea69cc54be44a8df2b3aa37 /activesupport/lib
parent7a83abe52fd982c2b34e8026f3ae34664ad60bc6 (diff)
downloadrails-843255a763c5e68beaa3a1b0bca306c625c30797.tar.gz
rails-843255a763c5e68beaa3a1b0bca306c625c30797.tar.bz2
rails-843255a763c5e68beaa3a1b0bca306c625c30797.zip
fixing activerecord tests [#4205 state:resolved]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
Diffstat (limited to 'activesupport/lib')
-rw-r--r--activesupport/lib/active_support/core_ext/class/delegating_attributes.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/core_ext/class/delegating_attributes.rb b/activesupport/lib/active_support/core_ext/class/delegating_attributes.rb
index df4954e67a..9b2dc21d87 100644
--- a/activesupport/lib/active_support/core_ext/class/delegating_attributes.rb
+++ b/activesupport/lib/active_support/core_ext/class/delegating_attributes.rb
@@ -27,7 +27,7 @@ private
# inheritance behavior, without having to store the object in an instance
# variable and look up the superclass chain manually.
def _stash_object_in_method(object, method, instance_reader = true)
- singleton_class.send(:remove_possible_method, method)
+ singleton_class.remove_possible_method(method)
singleton_class.send(:define_method, method) { object }
remove_possible_method(method)
define_method(method) { object } if instance_reader
@@ -37,7 +37,7 @@ private
singleton_class.send(:define_method, "#{name}=") do |value|
_stash_object_in_method(value, name, options[:instance_reader] != false)
end
- self.send("#{name}=", nil)
+ send("#{name}=", nil)
end
end