You are here

public function SiteAuditCheckCronEnabled::getAction in Site Audit 8.2

Same name and namespace in other branches
  1. 7 Check/Cron/Enabled.php \SiteAuditCheckCronEnabled::getAction()

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

Overrides SiteAuditCheckAbstract::getAction

File

Check/Cron/Enabled.php, line 68
Contains \SiteAudit\Check\Cron\Enabled.

Class

SiteAuditCheckCronEnabled
Class SiteAuditCheckCronEnabled.

Code

public function getAction() {
  if ($this->score == SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_FAIL) {
    return dt('Please visit /admin/config/system/cron and set the cron frequency to something other than Never but less than 24 hours.');
  }
  elseif ($this->score == SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_WARN) {
    if ($this->registry['cron_safe_threshold'] > 24 * 60 * 60) {
      return dt('Please visit /admin/config/system/cron and set the cron frequency to something less than 24 hours.');
    }
  }
}