Code cleaning.
This commit is contained in:
@@ -7,8 +7,8 @@ foreach ($_POST as $key => $val) { //Проверка всех значений
|
||||
}
|
||||
|
||||
$username = filter_input(INPUT_POST, 'username', FILTER_SANITIZE_SPECIAL_CHARS);
|
||||
$password = filter_input(INPUT_POST, 'password');
|
||||
$battle = filter_input(INPUT_COOKIE, 'battle');
|
||||
$password = $_POST['password'] ?? '';
|
||||
$battle = $_COOKIE['battle'] ?? '';
|
||||
$error = "";
|
||||
|
||||
if ($username && $password) {
|
||||
@@ -40,7 +40,6 @@ if ($username && $password) {
|
||||
}
|
||||
|
||||
db::c()->query('UPDATE `users` SET `sid` = "?s", `enter_game` = ?i WHERE `id` = ?i', session_id(), 1, $data['id']);
|
||||
$_SESSION['sid'] = session_id();
|
||||
|
||||
$sms = db::c()->query('SELECT * FROM `telegraph` WHERE `receiver` = ?i', $data['id']);
|
||||
while ($res = $sms->fetch_assoc()) {
|
||||
|
||||
Reference in New Issue
Block a user