diff options
Diffstat (limited to 'apis/cron.inc.php')
-rw-r--r-- | apis/cron.inc.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apis/cron.inc.php b/apis/cron.inc.php index 41370038..0b1e92a9 100644 --- a/apis/cron.inc.php +++ b/apis/cron.inc.php @@ -21,8 +21,8 @@ if (($report = Request::get('crashreport', false, 'string'))) { exit(0); } $str = array(); - foreach ($list as $item) { - Property::removeFromList(CRON_KEY_STATUS, $item); + foreach ($list as $subkey => $item) { + Property::removeFromListByKey(CRON_KEY_STATUS, $subkey); $entry = explode('|', $item, 2); if (count($entry) !== 2) continue; @@ -91,13 +91,13 @@ foreach (Hook::load('cron') as $hook) { $runtime = (time() - $status['start']); if ($runtime < 0) { // Clock skew - Property::removeFromList(CRON_KEY_STATUS, $status['string']); + Property::removeFromListByVal(CRON_KEY_STATUS, $status['string']); } elseif ($runtime < 900) { // Allow up to 15 minutes for a job to complete before we complain... continue; } else { // Consider job crashed - Property::removeFromList(CRON_KEY_STATUS, $status['string']); + Property::removeFromListByVal(CRON_KEY_STATUS, $status['string']); EventLog::failure('Cronjob for module ' . $hook->moduleId . ' seems to be stuck or has crashed.'); continue; } @@ -114,5 +114,5 @@ foreach (Hook::load('cron') as $hook) { // Logging EventLog::failure('Cronjob for module ' . $hook->moduleId . ' has crashed. Check the php or web server error log.', $e->getMessage()); } - Property::removeFromList(CRON_KEY_STATUS, $value); + Property::removeFromListByVal(CRON_KEY_STATUS, $value); } |