Apply fixes from StyleCI
[ci skip] [skip ci]
This commit is contained in:
parent
3d248c8cb4
commit
ee796c7ded
3 changed files with 13 additions and 7 deletions
|
@ -27,8 +27,11 @@ class AdminController extends Controller
|
|||
$settings[$setting->key] = $setting->value;
|
||||
}
|
||||
|
||||
$settings['default_user_quota'] = humanFileSize($this->getSetting('default_user_quota', stringToBytes('1G')), 0,
|
||||
true);
|
||||
$settings['default_user_quota'] = humanFileSize(
|
||||
$this->getSetting('default_user_quota', stringToBytes('1G')),
|
||||
0,
|
||||
true
|
||||
);
|
||||
|
||||
return view()->render($response, 'dashboard/system.twig', [
|
||||
'usersCount' => $usersCount = $this->database->query('SELECT COUNT(*) AS `count` FROM `users`')->fetch()->count,
|
||||
|
|
|
@ -101,11 +101,15 @@ class SettingController extends Controller
|
|||
private function updateSetting($key, $value = null)
|
||||
{
|
||||
if (!$this->database->query('SELECT `value` FROM `settings` WHERE `key` = '.$this->database->getPdo()->quote($key))->fetch()) {
|
||||
$this->database->query('INSERT INTO `settings`(`key`, `value`) VALUES ('.$this->database->getPdo()->quote($key).', ?)',
|
||||
$value);
|
||||
$this->database->query(
|
||||
'INSERT INTO `settings`(`key`, `value`) VALUES ('.$this->database->getPdo()->quote($key).', ?)',
|
||||
$value
|
||||
);
|
||||
} else {
|
||||
$this->database->query('UPDATE `settings` SET `value`=? WHERE `key` = '.$this->database->getPdo()->quote($key),
|
||||
$value);
|
||||
$this->database->query(
|
||||
'UPDATE `settings` SET `value`=? WHERE `key` = '.$this->database->getPdo()->quote($key),
|
||||
$value
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -64,5 +64,4 @@ class Theme
|
|||
{
|
||||
return 'default|'.self::DEFAULT_THEME_URL;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue