diff --git a/main.php b/main.php index 3e8c4d5..9d7d71e 100644 --- a/main.php +++ b/main.php @@ -325,8 +325,8 @@ function countmf() //global $user; // Защита от урона и сокрушение? - $zo = db::c()->query('SELECT 1 FROM `users_effects` WHERE `type` = 201 AND `owner_id` = ?i', $user['id'])->getNumRows(); - $sokr = db::c()->query('SELECT 1 FROM `users_effects` WHERE `type` = 202 AND `owner_id` = ?i', $user['id'])->getNumRows(); + $zo = db::c()->query('SELECT 1 FROM `users_effects` WHERE `type` = 201 AND `owner_id` = ?i', $_SESSION['uid'])->getNumRows(); + $sokr = db::c()->query('SELECT 1 FROM `users_effects` WHERE `type` = 202 AND `owner_id` = ?i', $_SESSION['uid'])->getNumRows(); $user = new User($_SESSION['uid']); $userDressedItems = new DressedItems($_SESSION['uid']);