mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-18 19:53:27 +02:00
Avoid globals where possible
$logged => logged() $account_logged => accountLogged()
This commit is contained in:
@@ -33,7 +33,9 @@ if ($db->hasTable('players')) {
|
||||
$time = time();
|
||||
function insert_sample_if_not_exist($p)
|
||||
{
|
||||
global $db, $success, $deleted, $time;
|
||||
global $success, $deleted, $time;
|
||||
|
||||
$db = app()->get('database');
|
||||
|
||||
$query = $db->query('SELECT `id` FROM `players` WHERE `name` = ' . $db->quote($p['name']));
|
||||
if ($query->rowCount() == 0) {
|
||||
|
Reference in New Issue
Block a user