Permalink
Browse files

avoid @transaction_joinable not initialized warning

  • Loading branch information...
1 parent ca92e92 commit 2b43021499f6e00a19eba3e7e48db403a61161bb @spastorino spastorino committed with Yehuda Katz Feb 22, 2010
@@ -113,7 +113,7 @@ def outside_transaction?
def transaction(options = {})
options.assert_valid_keys :requires_new, :joinable
- last_transaction_joinable = @transaction_joinable
+ last_transaction_joinable = defined?(@transaction_joinable) ? @transaction_joinable : nil
if options.has_key?(:joinable)
@transaction_joinable = options[:joinable]
else

0 comments on commit 2b43021

Please sign in to comment.