diff --git a/models/EffectsModel.php b/models/EffectsModel.php index 61a7251..2ee88b5 100644 --- a/models/EffectsModel.php +++ b/models/EffectsModel.php @@ -21,9 +21,11 @@ class EffectsModel */ public function getHideUserInfoStatus() { - while ($row = $this->DB->fetch_object()) { - if ($row->type == self::EFFECT_HIDEUSERINFO) { - return $row->time; + if ($this->DB) { + while ($row = $this->DB->fetch_object()) { + if ($row->type == self::EFFECT_HIDEUSERINFO) { + return $row->time; + } } } return 0;