You are here

public function SiteAuditCheckCacheDefaultClass::calculateScore in Site Audit 7

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

Overrides SiteAuditCheckAbstract::calculateScore

File

Check/Cache/DefaultClass.php, line 60
Contains \SiteAudit\Check\Cache\DefaultClass.

Class

SiteAuditCheckCacheDefaultClass
Class SiteAuditCheckCacheDefaultClass.

Code

public function calculateScore() {
  $this->registry['cache_default_class'] = variable_get('cache_default_class', 'DrupalDatabaseCache');
  if ($this->registry['cache_default_class'] == 'DrupalDatabaseCache' && is_array($this->registry['cache_backends']) && !empty($this->registry['cache_backends'])) {
    return SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_WARN;
  }
  return SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_INFO;
}