diff options
author | Andreas Fischer <bantu@phpbb.com> | 2015-06-13 15:18:44 +0200 |
---|---|---|
committer | Andreas Fischer <bantu@phpbb.com> | 2015-06-13 15:18:44 +0200 |
commit | e0d1f811145a0b49809147ae61b041672ac7cd06 (patch) | |
tree | 596efef78127709457758dc386ead3ff1e0a2096 /phpBB/phpbb/tree/nestedset.php | |
parent | a49bd38e833fbc42fdafd000872a810e6c6c37e4 (diff) | |
parent | bf7a4f629d2f5522f5a24404ecc5e884e7cedf84 (diff) | |
download | forums-e0d1f811145a0b49809147ae61b041672ac7cd06.tar forums-e0d1f811145a0b49809147ae61b041672ac7cd06.tar.gz forums-e0d1f811145a0b49809147ae61b041672ac7cd06.tar.bz2 forums-e0d1f811145a0b49809147ae61b041672ac7cd06.tar.xz forums-e0d1f811145a0b49809147ae61b041672ac7cd06.zip |
Merge branch '3.1.x'
* 3.1.x:
[ticket/13941] Workaround to fix the bug on php 5.5 with sqlite3
Diffstat (limited to 'phpBB/phpbb/tree/nestedset.php')
-rw-r--r-- | phpBB/phpbb/tree/nestedset.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/phpBB/phpbb/tree/nestedset.php b/phpBB/phpbb/tree/nestedset.php index 57d109652e..8490c7c299 100644 --- a/phpBB/phpbb/tree/nestedset.php +++ b/phpBB/phpbb/tree/nestedset.php @@ -837,7 +837,10 @@ abstract class nestedset implements \phpbb\tree\tree_interface ' . $this->get_sql_where('AND') . ' ORDER BY ' . $this->column_left_id . ', ' . $this->column_item_id . ' ASC'; $result = $this->db->sql_query($sql); - while ($row = $this->db->sql_fetchrow($result)) + $rows = $this->db->sql_fetchrowset($result); + $this->db->sql_freeresult($result); + + foreach ($rows as $row) { // First we update the left_id for this module if ($row[$this->column_left_id] != $new_id) @@ -862,7 +865,6 @@ abstract class nestedset implements \phpbb\tree\tree_interface } $new_id++; } - $this->db->sql_freeresult($result); if ($acquired_new_lock) { |