Manager: Don't enable modules which have unmet dependencies

This commit is contained in:
Johannes Meyer 2020-11-13 11:13:52 +01:00
parent aba8c4a8ba
commit 28c7c41b55
1 changed files with 7 additions and 0 deletions

View File

@ -260,6 +260,13 @@ class Manager
); );
} }
if ($this->hasUnmetDependencies($name)) {
throw new ConfigurationError(
t('Module "%s" can\'t be enabled. Module has unmet dependencies'),
$name
);
}
clearstatcache(true); clearstatcache(true);
$target = $this->installedBaseDirs[$name]; $target = $this->installedBaseDirs[$name];
$link = $this->enableDir . DIRECTORY_SEPARATOR . $name; $link = $this->enableDir . DIRECTORY_SEPARATOR . $name;