You are here

public function SiteAuditCheckBestPracticesFolderStructure::getAction in Site Audit 8.2

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

Overrides SiteAuditCheckAbstract::getAction

File

Check/BestPractices/FolderStructure.php, line 61
Contains \SiteAudit\Check\BestPractices\FolderStructure.

Class

SiteAuditCheckBestPracticesFolderStructure
Class SiteAuditCheckBestPracticesFolderStructure.

Code

public function getAction() {
  $message = "";
  if ($this->score == SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_WARN) {
    if (!$this->registry['contrib'] && !$this->registry['custom']) {
      $message .= dt('Put all the contrib modules inside the ./modules/contrib directory and custom modules inside the ./modules/custom directory.');
    }
    elseif (!$this->registry['contrib']) {
      $message .= dt('Put all the contrib modules inside the ./modules/contrib directory.');
    }
    elseif (!$this->registry['custom']) {
      $message .= dt('Put all the custom modules inside the ./modules/custom directory.');
    }
    return $message . ' ' . dt('Moving modules may cause errors, so refer to https://www.drupal.org/node/183681 for information on how to best proceed.');
  }
}