diff options
| author | Marc Alexander <admin@m-a-styles.de> | 2015-10-22 11:27:03 +0200 |
|---|---|---|
| committer | Mate Bartus <mate.bartus@gmail.com> | 2015-10-23 11:46:03 +0200 |
| commit | e0d06ee83ebf9ae72ef9746385155168fb083fa9 (patch) | |
| tree | 097cd28be8672432998b7a7bd4dd4f7d88825a70 /phpBB/phpbb/search/fulltext_native.php | |
| parent | 597297b169e2ae14684ad1f40c8e083be22b241d (diff) | |
| download | forums-e0d06ee83ebf9ae72ef9746385155168fb083fa9.tar forums-e0d06ee83ebf9ae72ef9746385155168fb083fa9.tar.gz forums-e0d06ee83ebf9ae72ef9746385155168fb083fa9.tar.bz2 forums-e0d06ee83ebf9ae72ef9746385155168fb083fa9.tar.xz forums-e0d06ee83ebf9ae72ef9746385155168fb083fa9.zip | |
[ticket/14044] Fix Sqlite error in tests
PHPBB3-14044
Diffstat (limited to 'phpBB/phpbb/search/fulltext_native.php')
| -rw-r--r-- | phpBB/phpbb/search/fulltext_native.php | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/phpBB/phpbb/search/fulltext_native.php b/phpBB/phpbb/search/fulltext_native.php index 3a74955a18..5fc276170d 100644 --- a/phpBB/phpbb/search/fulltext_native.php +++ b/phpBB/phpbb/search/fulltext_native.php @@ -1478,10 +1478,7 @@ class fulltext_native extends \phpbb\search\base $this->db->sql_return_on_error(false); } unset($new_words, $sql_ary); - } - else - { - $this->db->sql_transaction('begin'); + $this->db->sql_transaction('commit'); } // now update the search match table, remove links to removed words and add links to new words @@ -1513,6 +1510,11 @@ class fulltext_native extends \phpbb\search\base } } + if (!count($unique_add_words)) + { + $this->db->sql_transaction('begin'); + } + $this->db->sql_return_on_error(true); foreach ($words['add'] as $word_in => $word_ary) { |
