diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-05-09 17:01:51 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-05-09 17:01:51 -0300 |
commit | 05ab9024754beba25e64f94a13013b3ff42baa40 (patch) | |
tree | 25623c48db46f9c8ee29a4056bb48a064333ed1f /activerecord/lib | |
parent | 314cbea9a30679f3ebfcca0cd17756ca8cad81ea (diff) | |
parent | 198d9e3dfb943c309520e98b86d48c113eb5acbb (diff) | |
download | rails-05ab9024754beba25e64f94a13013b3ff42baa40.tar.gz rails-05ab9024754beba25e64f94a13013b3ff42baa40.tar.bz2 rails-05ab9024754beba25e64f94a13013b3ff42baa40.zip |
Merge pull request #15042 from arthurnn/revert_dirty_transactions
Reverts dirty track restore on transactions rollback
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/transactions.rb | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/transactions.rb b/activerecord/lib/active_record/transactions.rb index e31d28cfd1..17f76b63b3 100644 --- a/activerecord/lib/active_record/transactions.rb +++ b/activerecord/lib/active_record/transactions.rb @@ -350,7 +350,6 @@ module ActiveRecord end @_start_transaction_state[:level] = (@_start_transaction_state[:level] || 0) + 1 @_start_transaction_state[:frozen?] = @attributes.frozen? - @_start_transaction_state[:changed_attributes] ||= changed_attributes.dup end # Clear the new record state and id of a record. @@ -369,9 +368,6 @@ module ActiveRecord @attributes = @attributes.dup if @attributes.frozen? @new_record = restore_state[:new_record] @destroyed = restore_state[:destroyed] - changed_attributes.replace(restore_state[:changed_attributes]).delete_if do |attribute, old_value| - old_value == @attributes[attribute] - end if restore_state.has_key?(:id) write_attribute(self.class.primary_key, restore_state[:id]) else |