Merge pull request #1252 from arkonisus/patch-1

Update status.cron.php
pull/1292/head
Tim Zandbergen 2025-01-05 02:54:01 +01:00 committed by GitHub
commit dfb60f710a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ namespace {
// define won't accept array before php 7.0.0
// check if data is serialized (not needed when using php 7.0.0 and higher)
$data = @unserialize(PSM_CRON_ALLOW);
$data = (defined('PHP_MAJOR_VERSION') && PHP_MAJOR_VERSION >= 7) ? false : @unserialize(PSM_CRON_ALLOW);
$allow = $data === false ? PSM_CRON_ALLOW : $data;
if (!in_array($_SERVER['REMOTE_ADDR'], $allow) && !in_array($_SERVER["HTTP_X_FORWARDED_FOR"], $allow)