Commits a transaction or rollbacks on error

@return boolean
778484
public function commitTransaction()
    {

        if (empty($this->transactions) || !is_array($this->transactions)) {
            throw new QueryException(t("No transaction queries found"));
            $this->transactions = array();


            $this->resourceId->autocommit(TRUE); //Turns autocommit back on
            return false;
        }
        //Query transactions
        foreach ($this->transactions as $query) {


            if (!$this->exec($query)) {

                $this->resourceId->rollback(); //Rolls back the transaction;
                $this->transactions = array();
                $this->resourceId->autocommit(TRUE); //Turns autocommit back on


                return false;
            }
        }

        //Commit the transaction
        if (!$this->resourceId->commit()) {
            throw new QueryException(t("The transaction could not be committed"));
            $this->transactions = array();
            $this->resourceId->autocommit(TRUE); //Turns autocommit back on
            return false;
        }

        $this->transactions = array();
        $this->resourceId->autocommit(TRUE); //Turns autocommit back on
        return true;
    }
804994
public function commit()/*# : bool */
    {
        $ends = [ $this->front, $this->back ];
        $res  = false;

        foreach ($ends as $end) {
            // commit failed, set error
            if (!$end->commit()) {
                $this->setError(
                    $end->getError(),
                    $end->getErrorCode()
                );

            // one commit is ok, then all ok
            } else {
                $res = true;
            }
        }

        return $res;
    }
833570
public  function rollBack()
    {
        if ($this->transaction_level > 0){
            $this->transaction_level--;
            if ($this->transaction_level == 0){
                return parent::rollBack();
            }
            return true;
        }
        return false;
    }
247073
private function commit()
    {
        if ($this->inTransaction) {
            try {
                // commit read-write transaction which also releases the lock
                if ('sqlite' === $this->driver) {
                    $this->pdo->exec('COMMIT');
                } else {
                    $this->pdo->commit();
                }
                $this->inTransaction = false;
            } catch (\PDOException $e) {
                $this->rollback();

                throw $e;
            }
        }
    }
625654
public function rollbackTransaction() {
		$request = new CPS_RollbackTransactionRequest();
		$this->_lastResponse = $this->_connection->sendRequest($request);
		return true;
	}
664684
public function commitTransaction(): bool
	{
		if($this->transactionNestingLevel > 0 && --$this->transactionNestingLevel === 0)
		{
			return $this->pdo->commit();
		}

		return false;
	}
1234874
public function commit()
    {
        $return = true;
        $opcount = $this->nestedTransactionCount;

        if ($opcount > 0) {
            if ($opcount === 1) {
                if ($this->isUncommitable) {
                    throw new PropelException('Cannot commit because a nested transaction was rolled back');
                } else {
                    $return = parent::commit();
                    if ($this->useDebug) {
                        $this->log('Commit transaction', null, __METHOD__);
                    }
                }
            }

            $this->nestedTransactionCount--;
        }

        return $return;
    }
717814
public function rollbackTransaction()
    {
        $this->connect();
        if (!$this->_connection->inTransaction()) {
            return false;
        }

        return $this->_connection->rollBack();
    }
873981
public function commitTransaction()
    {
        try {
            $this->_pdo->commit();
            $this->_lastCheckTime = time();
        } catch (\PDOException $e) {
            $this->rollbackTransaction();
            $this->_error($e->getMessage(), FQDBException::PDO_CODE, $e);
        }
    }
1082532
public function commit()
    {
        if (!$this->getIsActive()) {
            throw new Exception('Failed to commit transaction: transaction was inactive.');
        }

        $this->_level--;
        if ($this->_level === 0) {
            Log::debug('Commit transaction' . __METHOD__);
            $this->db->pdo->commit();
            $this->db->trigger(Connection::EVENT_COMMIT_TRANSACTION);
            return;
        }

        $schema = $this->db->getSchema();
        if ($schema->supportsSavepoint()) {
            Log::debug('Release savepoint ' . $this->_level . __METHOD__);
            $schema->releaseSavepoint('LEVEL' . $this->_level);
        } else {
            Log::info('Transaction not committed: nested transaction not supported' . __METHOD__);
        }
    }
133532
public function rollbackTransaction()
    {
        if (!self::$transaction) {
            throw new TransactionException("There is no Active Transaction");
        }

        self::$transaction = false;
        foreach (self::$connectionList as $dbDriver) {
            $dbDriver->rollbackTransaction();
        }
    }
1205399
protected function _rollBack()
    {
        $this->_connect();
        $this->_connection->rollback();
        $this->_connection->autocommit(true);
    }
31285
public function commit()
    {
        $this->checkIfOpened();
        $response = $this->handleResponse($this->client->commitTransaction($this->transactionId, null, array(), $this->conn, $this->queryMode));
        $this->active = false;

        return $response;
    }
1095711
public function commitTransaction()
    {
        if (!self::$transaction) {
            throw new TransactionException("There is no Active Transaction");
        }

        self::$transaction = false;
        foreach (self::$connectionList as $dbDriver) {
            $dbDriver->commitTransaction();
        }
    }
577748
public function commit()
    {
        if ($this->rollbackAgain) {
            throw new \wf\db\Exception('Please throw exception after rollback in last catch block');
        }

        --$this->transactions;
    
        if($this->transactions == 0 && false === $this->dbh->commit()) {
            throw new \wf\db\Exception('transaction commit error: ' . $this->getLastErr());
        }

        if ($this->transactions < 0) {
            $this->transactions = 0;
        }
    }
143298
public function commit()
	{
		if($this->inTransaction == true)
		{
			throw new LikePDOException("There is no active transaction");
			return false;
		}
		else
		{
			if(!$this->driver->commitTransaction())
			{
				throw new LikePDOException("Failed to commit transaction");
				return false;
			}
			
			return true;
		}
	}
1270135
public final function commit()
   {
       foreach ($this->queue as $key => $value) {
           if (!$this->save($value)) {
               return false;
           }
           unset($this->queue[$key]);
       }
       return true;
   }