function RequiredModuleUninstallValidator::getModuleInfoByModule
Same name in other branches
- 8.9.x core/lib/Drupal/Core/Extension/RequiredModuleUninstallValidator.php \Drupal\Core\Extension\RequiredModuleUninstallValidator::getModuleInfoByModule()
- 10 core/lib/Drupal/Core/Extension/RequiredModuleUninstallValidator.php \Drupal\Core\Extension\RequiredModuleUninstallValidator::getModuleInfoByModule()
- 11.x core/lib/Drupal/Core/Extension/RequiredModuleUninstallValidator.php \Drupal\Core\Extension\RequiredModuleUninstallValidator::getModuleInfoByModule()
Returns the module info for a specific module.
Parameters
string $module: The name of the module.
Return value
array The module info, or empty array if that module does not exist.
1 call to RequiredModuleUninstallValidator::getModuleInfoByModule()
- RequiredModuleUninstallValidator::validate in core/
lib/ Drupal/ Core/ Extension/ RequiredModuleUninstallValidator.php - Determines the reasons a module can not be uninstalled.
File
-
core/
lib/ Drupal/ Core/ Extension/ RequiredModuleUninstallValidator.php, line 56
Class
- RequiredModuleUninstallValidator
- Ensures that required modules cannot be uninstalled.
Namespace
Drupal\Core\ExtensionCode
protected function getModuleInfoByModule($module) {
if ($this->moduleExtensionList
->exists($module)) {
return $this->moduleExtensionList
->get($module)->info;
}
return [];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.