aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib
diff options
context:
space:
mode:
authorIvan Evtukhovich <evtuhovich@gmail.com>2010-12-09 00:41:47 +0300
committerIvan Evtukhovich <evtuhovich@gmail.com>2010-12-09 00:41:47 +0300
commit53bbbcc6638a9df86e74e4e420840f076e7c2994 (patch)
tree3ddd2d2c755f244b032c91a48b909aeed99c196e /activerecord/lib
parent8c822e8e2943ca138cc465f5619ce1f602214941 (diff)
downloadrails-53bbbcc6638a9df86e74e4e420840f076e7c2994.tar.gz
rails-53bbbcc6638a9df86e74e4e420840f076e7c2994.tar.bz2
rails-53bbbcc6638a9df86e74e4e420840f076e7c2994.zip
Fix doc about nested transaction rollback
Because AR::Rollback do not reraise and inner transaction is not "real" nothing rollback at all
Diffstat (limited to 'activerecord/lib')
-rw-r--r--activerecord/lib/active_record/transactions.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/transactions.rb b/activerecord/lib/active_record/transactions.rb
index 654c475aed..181280baaa 100644
--- a/activerecord/lib/active_record/transactions.rb
+++ b/activerecord/lib/active_record/transactions.rb
@@ -141,7 +141,8 @@ module ActiveRecord
# end
# end
#
- # User.find(:all) # => empty
+ # User.find(:all) # => Return both Kotori and Nemu, because inner transaction do not rollback
+ # # without :requiers_new => true option, and Rollback exception do not reraise
#
# It is also possible to requires a sub-transaction by passing
# <tt>:requires_new => true</tt>. If anything goes wrong, the