mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
$db-> to phpbb::$db->
git-svn-id: file:///svn/phpbb/trunk@9336 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -239,7 +239,7 @@ _sql($sql, $errored, $error_ary);
|
||||
/* Optimize/vacuum analyze the tables where appropriate
|
||||
// this should be done for each version in future along with
|
||||
// the version number update
|
||||
switch ($db->dbms_type)
|
||||
switch (phpbb::$db->dbms_type)
|
||||
{
|
||||
case 'mysql':
|
||||
$sql = 'OPTIMIZE TABLE ' . $table_prefix . 'auth_access, ' . $table_prefix . 'banlist, ' . $table_prefix . 'categories, ' . $table_prefix . 'config, ' . $table_prefix . 'disallow, ' . $table_prefix . 'forum_prune, ' . $table_prefix . 'forums, ' . $table_prefix . 'groups, ' . $table_prefix . 'posts, ' . $table_prefix . 'posts_text, ' . $table_prefix . 'privmsgs, ' . $table_prefix . 'privmsgs_text, ' . $table_prefix . 'ranks, ' . $table_prefix . 'search_results, ' . $table_prefix . 'search_wordlist, ' . $table_prefix . 'search_wordmatch, ' . $table_prefix . 'sessions_keys' . $table_prefix . 'smilies, ' . $table_prefix . 'themes, ' . $table_prefix . 'themes_name, ' . $table_prefix . 'topics, ' . $table_prefix . 'topics_watch, ' . $table_prefix . 'user_group, ' . $table_prefix . 'users, ' . $table_prefix . 'vote_desc, ' . $table_prefix . 'vote_results, ' . $table_prefix . 'vote_voters, ' . $table_prefix . 'words';
|
||||
|
@@ -1488,7 +1488,7 @@ class install_install extends module
|
||||
if (!$user_id)
|
||||
{
|
||||
// If we can't insert this user then continue to the next one to avoid inconsistant data
|
||||
$this->p_master->db_error('Unable to insert bot into users table', $db->sql_error_sql, __LINE__, __FILE__);
|
||||
$this->p_master->db_error('Unable to insert bot into users table', phpbb::$db->sql_error_sql, __LINE__, __FILE__);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
@@ -414,9 +414,9 @@ class install_update extends module
|
||||
$sql = 'SELECT *
|
||||
FROM ' . STYLES_THEME_TABLE . "
|
||||
WHERE theme_name = 'prosilver'";
|
||||
$result = $db->sql_query($sql);
|
||||
$theme = $db->sql_fetchrow($result);
|
||||
$db->sql_freeresult($result);
|
||||
$result = phpbb::$db->sql_query($sql);
|
||||
$theme = phpbb::$db->sql_fetchrow($result);
|
||||
phpbb::$db->sql_freeresult($result);
|
||||
|
||||
if ($theme)
|
||||
{
|
||||
@@ -461,17 +461,17 @@ class install_update extends module
|
||||
'theme_data' => $theme['theme_data']
|
||||
);
|
||||
|
||||
$sql = 'UPDATE ' . STYLES_THEME_TABLE . ' SET ' . $db->sql_build_array('UPDATE', $sql_ary) . '
|
||||
$sql = 'UPDATE ' . STYLES_THEME_TABLE . ' SET ' . phpbb::$db->sql_build_array('UPDATE', $sql_ary) . '
|
||||
WHERE theme_id = ' . $theme['theme_id'];
|
||||
$db->sql_query($sql);
|
||||
phpbb::$db->sql_query($sql);
|
||||
|
||||
phpbb::$acm->destroy_sql(STYLES_THEME_TABLE);
|
||||
}
|
||||
}
|
||||
|
||||
$db->sql_return_on_error(true);
|
||||
$db->sql_query('DELETE FROM ' . CONFIG_TABLE . " WHERE config_name = 'version_update_from'");
|
||||
$db->sql_return_on_error(false);
|
||||
phpbb::$db->sql_return_on_error(true);
|
||||
phpbb::$db->sql_query('DELETE FROM ' . CONFIG_TABLE . " WHERE config_name = 'version_update_from'");
|
||||
phpbb::$db->sql_return_on_error(false);
|
||||
|
||||
phpbb::$acm->purge();
|
||||
}
|
||||
@@ -1513,14 +1513,14 @@ class install_update extends module
|
||||
$sql = 'SELECT template_name, template_path
|
||||
FROM ' . STYLES_TEMPLATE_TABLE . "
|
||||
WHERE LOWER(template_name) NOT IN ('subsilver2', 'prosilver')";
|
||||
$result = $db->sql_query($sql);
|
||||
$result = phpbb::$db->sql_query($sql);
|
||||
|
||||
$templates = array();
|
||||
while ($row = $db->sql_fetchrow($result))
|
||||
while ($row = phpbb::$db->sql_fetchrow($result))
|
||||
{
|
||||
$templates[] = $row;
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
phpbb::$db->sql_freeresult($result);
|
||||
|
||||
if (sizeof($templates))
|
||||
{
|
||||
|
Reference in New Issue
Block a user