summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@bofh.bg>2012-01-19 15:02:32 +0100
committerAndrey Andreev <narf@bofh.bg>2012-01-19 15:02:32 +0100
commit72d7a6e2cbf1bd797bab7b14912a207f4522953a (patch)
tree8ec90e36960cbf18dca24a80628cdd172671824f
parent53921cab6f979bedef6deb837aea54f354b1f7e6 (diff)
Some cleaning
-rw-r--r--system/database/drivers/sqlite3/sqlite3_driver.php21
1 files changed, 3 insertions, 18 deletions
diff --git a/system/database/drivers/sqlite3/sqlite3_driver.php b/system/database/drivers/sqlite3/sqlite3_driver.php
index b82ae1ecd..8a7dbe1f1 100644
--- a/system/database/drivers/sqlite3/sqlite3_driver.php
+++ b/system/database/drivers/sqlite3/sqlite3_driver.php
@@ -188,13 +188,8 @@ class CI_DB_sqlite3_driver extends CI_DB {
*/
public function trans_begin($test_mode = FALSE)
{
- if ( ! $this->trans_enabled)
- {
- return TRUE;
- }
-
// When transactions are nested we only begin/commit/rollback the outermost ones
- if ($this->_trans_depth > 0)
+ if ( ! $this->trans_enabled OR $this->_trans_depth > 0)
{
return TRUE;
}
@@ -216,13 +211,8 @@ class CI_DB_sqlite3_driver extends CI_DB {
*/
public function trans_commit()
{
- if ( ! $this->trans_enabled)
- {
- return TRUE;
- }
-
// When transactions are nested we only begin/commit/rollback the outermost ones
- if ($this->_trans_depth > 0)
+ if ( ! $this->trans_enabled OR $this->_trans_depth > 0)
{
return TRUE;
}
@@ -239,13 +229,8 @@ class CI_DB_sqlite3_driver extends CI_DB {
*/
public function trans_rollback()
{
- if ( ! $this->trans_enabled)
- {
- return TRUE;
- }
-
// When transactions are nested we only begin/commit/rollback the outermost ones
- if ($this->_trans_depth > 0)
+ if ( ! $this->trans_enabled OR $this->_trans_depth > 0)
{
return TRUE;
}