From ab6ebcceb1052f55ff8a93cf2a80b79f32c50ee9 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Mon, 6 Feb 2012 17:10:44 -0800 Subject: copy over columns hash on reload --- activerecord/lib/active_record/persistence.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'activerecord') diff --git a/activerecord/lib/active_record/persistence.rb b/activerecord/lib/active_record/persistence.rb index 09ee2ba61d..9bc046c775 100644 --- a/activerecord/lib/active_record/persistence.rb +++ b/activerecord/lib/active_record/persistence.rb @@ -287,6 +287,7 @@ module ActiveRecord IdentityMap.without do fresh_object = self.class.unscoped { self.class.find(id, options) } @attributes.update(fresh_object.instance_variable_get('@attributes')) + @columns_hash = fresh_object.instance_variable_get('@columns_hash') end @attributes_cache = {} -- cgit v1.2.3