mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-26 03:48:53 +00:00
[ticket/10601] Cosmetic code changes
- Removed the double line before the addition - Moved the condition of the WHERE so that both are in the same line - Removed TABs from the black lines - Used double quotes instead of escaped single quotes. PHPBB3-10601
This commit is contained in:
parent
85ebbbaec4
commit
1f9eaa1c56
1 changed files with 5 additions and 7 deletions
|
@ -2749,14 +2749,12 @@ function change_database_data(&$no_updates, $version)
|
||||||
$config->set('site_home_url', '');
|
$config->set('site_home_url', '');
|
||||||
$config->set('site_home_text', '');
|
$config->set('site_home_text', '');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// ticket/10601: Make inbox default. Add basename to ucp's pm category
|
// ticket/10601: Make inbox default. Add basename to ucp's pm category
|
||||||
// Check if this was already applied
|
// Check if this was already applied
|
||||||
$sql = 'SELECT module_id, module_basename, parent_id, left_id, right_id
|
$sql = 'SELECT module_id, module_basename, parent_id, left_id, right_id
|
||||||
FROM ' . MODULES_TABLE . '
|
FROM ' . MODULES_TABLE . '
|
||||||
WHERE
|
WHERE module_basename = "ucp_pm"
|
||||||
module_basename = \'ucp_pm\'
|
|
||||||
ORDER BY module_id';
|
ORDER BY module_id';
|
||||||
$result = $db->sql_query_limit($sql, 1);
|
$result = $db->sql_query_limit($sql, 1);
|
||||||
|
|
||||||
|
@ -2766,13 +2764,13 @@ function change_database_data(&$no_updates, $version)
|
||||||
if ($row['left_id'] === $row['right_id'] - 1)
|
if ($row['left_id'] === $row['right_id'] - 1)
|
||||||
{
|
{
|
||||||
// This update is still not applied. Applying it
|
// This update is still not applied. Applying it
|
||||||
|
|
||||||
$sql = 'UPDATE ' . MODULES_TABLE . '
|
$sql = 'UPDATE ' . MODULES_TABLE . '
|
||||||
SET module_basename = \'ucp_pm\'
|
SET module_basename = \'ucp_pm\'
|
||||||
WHERE module_id = ' . (int) $row['parent_id'];
|
WHERE module_id = ' . (int) $row['parent_id'];
|
||||||
|
|
||||||
_sql($sql, $errored, $error_ary);
|
_sql($sql, $errored, $error_ary);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
|
|
Loading…
Add table
Reference in a new issue