diff options
| author | 2014-10-05 23:20:16 +0200 | |
|---|---|---|
| committer | 2014-10-05 23:20:16 +0200 | |
| commit | e2da6e6e6b871dc3dbc289cdd40ba401a21d8e91 (patch) | |
| tree | 5514a38226efe52f8084b2af29109cdbc5504507 /lib/Minz/ModelPdo.php | |
| parent | f5a95d383c056fddd86e34024cba3444b527730d (diff) | |
Refactor feedController
See https://github.com/marienfressinaud/FreshRSS/issues/655
Diffstat (limited to 'lib/Minz/ModelPdo.php')
| -rw-r--r-- | lib/Minz/ModelPdo.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Minz/ModelPdo.php b/lib/Minz/ModelPdo.php index b4bfca746..69e46fb39 100644 --- a/lib/Minz/ModelPdo.php +++ b/lib/Minz/ModelPdo.php @@ -16,6 +16,7 @@ class Minz_ModelPdo { public static $useSharedBd = true; private static $sharedBd = null; private static $sharedPrefix; + private static $has_transaction = false; protected static $sharedDbType; /** @@ -91,12 +92,18 @@ class Minz_ModelPdo { public function beginTransaction() { $this->bd->beginTransaction(); + $this->has_transaction = true; + } + public function hasTransaction() { + return $this->has_transaction; } public function commit() { $this->bd->commit(); + $this->has_transaction = false; } public function rollBack() { $this->bd->rollBack(); + $this->has_transaction = false; } public static function clean() { |
