aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/attribute_methods/dirty.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/lib/active_record/attribute_methods/dirty.rb')
-rw-r--r--activerecord/lib/active_record/attribute_methods/dirty.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/attribute_methods/dirty.rb b/activerecord/lib/active_record/attribute_methods/dirty.rb
index 9ec1fbeee1..911c908c8b 100644
--- a/activerecord/lib/active_record/attribute_methods/dirty.rb
+++ b/activerecord/lib/active_record/attribute_methods/dirty.rb
@@ -161,7 +161,7 @@ module ActiveRecord
if partial_updates?
# Serialized attributes should always be written in case they've been
# changed in place.
- update_without_dirty(changed | self.class.serialized_attributes.keys)
+ update_without_dirty(changed | (attributes.keys & self.class.serialized_attributes.keys))
else
update_without_dirty
end