function ModuleExtensionList::doScanExtensions

Same name in other branches
  1. 8.9.x core/lib/Drupal/Core/Extension/ModuleExtensionList.php \Drupal\Core\Extension\ModuleExtensionList::doScanExtensions()
  2. 10 core/lib/Drupal/Core/Extension/ModuleExtensionList.php \Drupal\Core\Extension\ModuleExtensionList::doScanExtensions()
  3. 11.x core/lib/Drupal/Core/Extension/ModuleExtensionList.php \Drupal\Core\Extension\ModuleExtensionList::doScanExtensions()

Overrides ExtensionList::doScanExtensions

File

core/lib/Drupal/Core/Extension/ModuleExtensionList.php, line 137

Class

ModuleExtensionList
Provides a list of available modules.

Namespace

Drupal\Core\Extension

Code

protected function doScanExtensions() {
    $extensions = parent::doScanExtensions();
    $profiles = $this->profileList
        ->getList();
    // Modify the active profile object that was previously added to the module
    // list.
    if ($this->installProfile && isset($profiles[$this->installProfile])) {
        $extensions[$this->installProfile] = $profiles[$this->installProfile];
    }
    return $extensions;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.