From eaeaad5e974223d814ad7e0fa01d1923dc3c571a Mon Sep 17 00:00:00 2001 From: Katsumi Honda Date: Tue, 19 Mar 2013 17:56:09 +0900 Subject: Fixed problem for transaction test mode. trans_complete function is committed in test mode. Because any database drivers are set _trans_failure in test_mode, And trans_complete function is not evaluate _trans_failure. --- system/database/DB_driver.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'system/database/DB_driver.php') diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php index 18dbbc76e..3e6378448 100644 --- a/system/database/DB_driver.php +++ b/system/database/DB_driver.php @@ -816,7 +816,7 @@ abstract class CI_DB_driver { } // The query() function will set this flag to FALSE in the event that a query failed - if ($this->_trans_status === FALSE) + if ($this->_trans_status === FALSE || $this->_trans_failure === TRUE) { $this->trans_rollback(); @@ -1859,4 +1859,4 @@ abstract class CI_DB_driver { } /* End of file DB_driver.php */ -/* Location: ./system/database/DB_driver.php */ \ No newline at end of file +/* Location: ./system/database/DB_driver.php */ -- cgit v1.2.3-24-g4f1b