Flowdock
method

within_new_transaction

Importance_0
v4.0.2 - Show latest stable - 0 notes - Class: ActiveRecord::ConnectionAdapters::DatabaseStatements
within_new_transaction(options = {}) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb, line 208
      def within_new_transaction(options = {}) #:nodoc:
        transaction = begin_transaction(options)
        yield
      rescue Exception => error
        rollback_transaction if transaction
        raise
      ensure
        begin
          commit_transaction unless error
        rescue Exception
          rollback_transaction
          raise
        end
      end
Register or log in to add new notes.