fix PHP 8.0 Fatal error

This commit is contained in:
Ralf Becker 2021-03-21 18:25:14 +01:00
parent efd480c468
commit dac55616af

View File

@ -136,7 +136,7 @@ class Preferences
$this->account_id = self::FORCED_ID;
}
// if we got instancated for a group, need to set offset of DEFAULT_ID!
elseif ($account_id < 0 || !is_numeric($account_id) && ($account_id = get_account_id($account_id)) < 0)
elseif ((int)$account_id < 0 || !is_numeric($account_id) && ($account_id = get_account_id($account_id)) < 0)
{
$this->account_id = $account_id + self::DEFAULT_ID;
}