Fix deprecation warning in PHP 8.x

This commit is contained in:
Kijin Sung 2023-06-26 14:46:19 +09:00
parent 6479f3967b
commit 9fbcda3e79

View file

@ -318,7 +318,7 @@ class Context
}
}
$lang_type = preg_replace('/[^a-zA-Z0-9_-]/', '', $lang_type);
$lang_type = preg_replace('/[^a-zA-Z0-9_-]/', '', $lang_type ?? '');
if ($set_lang_cookie)
{
setcookie('lang_type', $lang_type, time() + 86400 * 365, \RX_BASEURL, '', !!config('session.use_ssl_cookies'));