diff options
author | Jon Leighton <j@jonathanleighton.com> | 2011-12-24 00:15:08 +0000 |
---|---|---|
committer | Jon Leighton <j@jonathanleighton.com> | 2011-12-24 11:08:16 +0000 |
commit | a1ee3ac654078ef57832b8e9833ac13afcb944fa (patch) | |
tree | 8900f0f628405e3cd39baa96f54e00cecfdca86e /activerecord/lib/active_record | |
parent | 1029c511f190fbcf4214fa89118bd7264ef9959c (diff) | |
download | rails-a1ee3ac654078ef57832b8e9833ac13afcb944fa.tar.gz rails-a1ee3ac654078ef57832b8e9833ac13afcb944fa.tar.bz2 rails-a1ee3ac654078ef57832b8e9833ac13afcb944fa.zip |
Ensure attribute methods are included after all the AR stuff
Diffstat (limited to 'activerecord/lib/active_record')
-rw-r--r-- | activerecord/lib/active_record/attribute_methods.rb | 2 | ||||
-rw-r--r-- | activerecord/lib/active_record/core.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/attribute_methods.rb b/activerecord/lib/active_record/attribute_methods.rb index 7cb4326754..44b0956e4e 100644 --- a/activerecord/lib/active_record/attribute_methods.rb +++ b/activerecord/lib/active_record/attribute_methods.rb @@ -52,7 +52,7 @@ module ActiveRecord end def undefine_attribute_methods - super + super if attribute_methods_generated? @attribute_methods_generated = false end diff --git a/activerecord/lib/active_record/core.rb b/activerecord/lib/active_record/core.rb index 8143e31f26..4f118e46a9 100644 --- a/activerecord/lib/active_record/core.rb +++ b/activerecord/lib/active_record/core.rb @@ -67,7 +67,7 @@ module ActiveRecord # The connection handler class_attribute :connection_handler, :instance_writer => false - initialize_generated_modules + initialize_generated_modules unless self == Base end module ClassMethods |