/** * Rollback transaction * @return bool */ protected function _rollBack() { if ($this->_nestedTransactionsCounter <= 0) { throw new Zend_Db_Adapter_Exception('Nested transactions error'); } if (!$this->_isInRollback) { $result = parent::_rollBack(); $this->_isInRollback = true; } else { $result = true; } $this->_nestedTransactionsCounter--; if ($this->_nestedTransactionsCounter == 0) { $this->_isInRollback = false; } return $result; }