diff options
author | Oscar Del Ben <info@oscardelben.com> | 2012-05-14 13:56:26 -0700 |
---|---|---|
committer | Oscar Del Ben <info@oscardelben.com> | 2012-05-14 13:56:26 -0700 |
commit | f2af398efa40dff20d4841d595bc0366660707cc (patch) | |
tree | 8af0c081de5f2d6cfc1b033c5eefa9954de569dd /activerecord/lib/active_record/transactions.rb | |
parent | 59462c1e310b85569785cf5f491611e670c2755b (diff) | |
parent | 151aa9abae131f1a03513f756aeaef2fc403f9bb (diff) | |
download | rails-f2af398efa40dff20d4841d595bc0366660707cc.tar.gz rails-f2af398efa40dff20d4841d595bc0366660707cc.tar.bz2 rails-f2af398efa40dff20d4841d595bc0366660707cc.zip |
Merge branch 'master' of github.com:lifo/docrails
Diffstat (limited to 'activerecord/lib/active_record/transactions.rb')
-rw-r--r-- | activerecord/lib/active_record/transactions.rb | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/activerecord/lib/active_record/transactions.rb b/activerecord/lib/active_record/transactions.rb index 743dfc5a38..64e5640791 100644 --- a/activerecord/lib/active_record/transactions.rb +++ b/activerecord/lib/active_record/transactions.rb @@ -302,12 +302,8 @@ module ActiveRecord def remember_transaction_record_state #:nodoc: @_start_transaction_state ||= {} @_start_transaction_state[:id] = id if has_attribute?(self.class.primary_key) - unless @_start_transaction_state.include?(:new_record) - @_start_transaction_state[:new_record] = @new_record - end - unless @_start_transaction_state.include?(:destroyed) - @_start_transaction_state[:destroyed] = @destroyed - end + @_start_transaction_state[:new_record] = @new_record + @_start_transaction_state[:destroyed] = @destroyed @_start_transaction_state[:level] = (@_start_transaction_state[:level] || 0) + 1 end |