1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-02-25 04:23:38 +01:00

[ticket/9628] _add_module 'after'-parameter does not work correctly.

The modules were grouped by left_id so num_modules is always one (hopefully), but the number of rows is the actual value we'd like to know. Removing the GROUP BY resolves the issue.

PHPBB3-9628
This commit is contained in:
Joas Schilling 2010-05-28 13:13:53 +02:00
parent 6d7e30ae99
commit 4637709f0a

View File

@ -685,7 +685,6 @@ function _add_modules($modules_to_install)
WHERE module_class = '" . $db->sql_escape($module_data['class']) . "'
AND parent_id = {$parent_id}
AND left_id BETWEEN {$first_left_id} AND {$module_row['left_id']}
GROUP BY left_id
ORDER BY left_id";
$result = $db->sql_query($sql);
$steps = (int) $db->sql_fetchfield('num_modules');