class errors

This commit is contained in:
Igor Barkov (iwork) 2020-07-20 17:25:02 +03:00
parent d3a0465f9a
commit b358d19893

View File

@ -8,7 +8,7 @@
class DressedItems
{
protected static $DB;
protected $DBSUM;
protected static $DBSUM;
protected static $USERID;
private $dressedItem;
@ -49,7 +49,7 @@ SELECT SUM(add_strength) as sum_strength,
SUM(add_max_physical_damage) as sum_max_phys_damage
FROM inventory WHERE owner_id = ?i AND dressed_slot > 0
SQL;
$this->DBSUM = db::c()->query($query, self::$USERID)->fetch_assoc();
self::$DBSUM = db::c()->query($query, self::$USERID)->fetch_assoc();
} catch (Exception $e) {
echo '<div class="debug">Не прогрузилась таблица inventory (SUM) для класса DressedItems:' . $e . '</div>';
}
@ -69,10 +69,10 @@ SQL;
protected function getBonuses()
{
if (!$this->DBSUM) {
if (!self::$DBSUM) {
self::getBonusesFromDressedItems();
}
return $this->DBSUM;
return self::$DBSUM;
}
public function getStrengthBonus()