diff --git a/activerecord/lib/active_record/core.rb b/activerecord/lib/active_record/core.rb index 20d9e7a9cab84adfbea8e758be31714274766e6b..df795df52e426192ab33e9a509ede346b7562dc1 100644 --- a/activerecord/lib/active_record/core.rb +++ b/activerecord/lib/active_record/core.rb @@ -356,6 +356,8 @@ def init_from_db(attributes) @new_record = false @attributes = attributes + self.class.define_attribute_methods + yield self if block_given? _run_find_callbacks