diff options
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/attribute_methods.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/activerecord/lib/active_record/attribute_methods.rb b/activerecord/lib/active_record/attribute_methods.rb index 40ff273846..284ae2bebc 100644 --- a/activerecord/lib/active_record/attribute_methods.rb +++ b/activerecord/lib/active_record/attribute_methods.rb @@ -31,9 +31,8 @@ module ActiveRecord def defined_activerecord_methods active_record = ActiveRecord::Base super_klass = ActiveRecord::Base.superclass - methods = active_record.public_instance_methods - super_klass.public_instance_methods - methods += active_record.private_instance_methods - super_klass.private_instance_methods - methods += active_record.protected_instance_methods - super_klass.protected_instance_methods + methods = (active_record.instance_methods - super_klass.instance_methods) + + (active_record.private_instance_methods - super_klass.private_instance_methods) methods.map {|m| m.to_s }.to_set end end |