diff options
author | Sean Griffin <sean@seantheprogrammer.com> | 2015-02-05 07:04:23 -0700 |
---|---|---|
committer | Sean Griffin <sean@seantheprogrammer.com> | 2015-02-05 07:04:23 -0700 |
commit | 494c789443fcd8bf7b96f805049625d546666a40 (patch) | |
tree | d69451e78cabb90797d9deab137bfc6273a07190 | |
parent | f499ecf961115a17715c1d094ece65861ee5fac0 (diff) | |
parent | 68198c3e38d7d5e69564cfd5fdb982673aedaee8 (diff) | |
download | rails-494c789443fcd8bf7b96f805049625d546666a40.tar.gz rails-494c789443fcd8bf7b96f805049625d546666a40.tar.bz2 rails-494c789443fcd8bf7b96f805049625d546666a40.zip |
Merge pull request #18820 from tycooon/transaction-rollback-fix
Fix transaction rollback in case of aborting thread
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/transaction.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb b/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb index 1eb30956d4..11440e30d4 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb @@ -185,7 +185,7 @@ module ActiveRecord ensure unless error if Thread.current.status == 'aborting' - rollback_transaction + rollback_transaction if transaction else begin commit_transaction |