28 lines
467 B
PHP
28 lines
467 B
PHP
<?php
|
|
|
|
namespace FluentMail\App\Services\DB\QueryBuilder;
|
|
|
|
class Transaction extends QueryBuilderHandler
|
|
{
|
|
|
|
/**
|
|
* Commit the database changes
|
|
*/
|
|
public function commit()
|
|
{
|
|
$this->db->query('COMMIT');
|
|
|
|
throw new TransactionHaltException();
|
|
}
|
|
|
|
/**
|
|
* Rollback the database changes
|
|
*/
|
|
public function rollback()
|
|
{
|
|
$this->db->query('ROLLBACK');
|
|
|
|
throw new TransactionHaltException();
|
|
}
|
|
}
|