You are here

public function SiteAuditCheckCronRunning::calculateScore in Site Audit 7

Implements \SiteAudit\Check\Abstract\calculateScore().

Overrides SiteAuditCheckAbstract::calculateScore

File

Check/Cron/Running.php, line 67
Contains \SiteAudit\Check\Cron\Running.

Class

SiteAuditCheckCronRunning
Class SiteAuditCheckCronRunning.

Code

public function calculateScore() {
  $this->registry['cron_semaphore'] = variable_get('cron_semaphore');
  if ($this->registry['cron_semaphore'] && time() - $this->registry['cron_semaphore'] > 3600) {
    return SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_WARN;
  }
  return SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_INFO;
}