Fix warning in PHP8.0

This commit is contained in:
BJRambo 2021-07-15 03:26:49 +09:00
parent ce694e179c
commit c7f84a178d
4 changed files with 9 additions and 5 deletions

View file

@ -1070,10 +1070,10 @@ class ncenterliteController extends ncenterlite
}
$_latest_notify_id = array_slice($_output->data, 0, 1);
$_latest_notify_id = $_latest_notify_id[0]->notify;
$_latest_notify_id = count($_latest_notify_id) > 0 ? $_latest_notify_id[0]->notify : "";
Context::set('ncenterlite_latest_notify_id', $_latest_notify_id);
if($_COOKIE['_ncenterlite_hide_id'] && $_COOKIE['_ncenterlite_hide_id'] == $_latest_notify_id)
if(isset($_COOKIE['_ncenterlite_hide_id']) && $_COOKIE['_ncenterlite_hide_id'] == $_latest_notify_id)
{
return;
}