diff --git a/src/BaseModule.php b/src/BaseModule.php index a9f67f237..c1f35533b 100644 --- a/src/BaseModule.php +++ b/src/BaseModule.php @@ -140,11 +140,7 @@ abstract class BaseModule return false; } - if (empty($a->user)) { - return false; - } - - $sec_hash = hash('whirlpool', $a->user['guid'] . $a->user['prvkey'] . session_id() . $x[0] . $typename); + $sec_hash = hash('whirlpool', ($a->user['guid'] ?? '') . ($a->user['prvkey'] ?? '') . session_id() . $x[0] . $typename); return ($sec_hash == $x[1]); }