Modules/Manager: Fix that non-existent modules can be disabled
fixes #9374
This commit is contained in:
parent
3c35674e14
commit
c3fe14a205
|
@ -281,7 +281,10 @@ class Manager
|
|||
public function disableModule($name)
|
||||
{
|
||||
if (! $this->hasEnabled($name)) {
|
||||
return $this;
|
||||
throw new ConfigurationError(
|
||||
'Cannot disable module "%s". Module is not installed.',
|
||||
$name
|
||||
);
|
||||
}
|
||||
|
||||
if (! is_writable($this->enableDir)) {
|
||||
|
|
Loading…
Reference in New Issue