method

rollback_records

Importance_0
v4.2.1 - Show latest stable - 0 notes - Class: Transaction
rollback_records() 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/transaction.rb, line 69
      def rollback_records
        ite = records.uniq
        while record = ite.shift
          begin
            record.rolledback! full_rollback?
          rescue => e
            raise if ActiveRecord::Base.raise_in_transactional_callbacks
            record.logger.error(e) if record.respond_to?(:logger) && record.logger
          end
        end
      ensure
        ite.each do |i|
          i.rolledback!(full_rollback?, false)
        end
      end
Register or log in to add new notes.