public function SiteAuditCheckBase::getResult in Site Audit 8.3
Determine the result message based on the score.
Return value
string Human readable message for a given status.
File
- src/
Plugin/ SiteAuditCheckBase.php, line 96
Class
- SiteAuditCheckBase
- Base class for Site Audit Check plugins.
Namespace
Drupal\site_audit\PluginCode
public function getResult() {
if ($this->optOut) {
return $this
->t('Opted-out in site configuration.');
}
switch ($this->score) {
case SiteAuditCheckBase::AUDIT_CHECK_SCORE_PASS:
return $this
->getResultPass();
case SiteAuditCheckBase::AUDIT_CHECK_SCORE_WARN:
return $this
->getResultWarn();
case SiteAuditCheckBase::AUDIT_CHECK_SCORE_INFO:
return $this
->getResultInfo();
default:
return $this
->getResultFail();
}
}