Module list should not throw Exceptions if no config is present

This commit is contained in:
Thomas Gelf 2014-04-17 21:16:51 +00:00
parent 039aa76467
commit fa3e7f9fc2
1 changed files with 4 additions and 4 deletions

View File

@ -128,10 +128,10 @@ class Manager
private function detectEnabledModules() private function detectEnabledModules()
{ {
$canonical = $this->enableDir; $canonical = $this->enableDir;
if ($canonical === false) { if ($canonical === false || ! file_exists($canonical)) {
throw new NotReadableError( // TODO: I guess the check for false has something to do with a
'Cannot read enabled modules. Module directory "' . $this->enableDir . '" does not exist' // call to realpath no longer present
); return;
} }
if (!is_dir($this->enableDir)) { if (!is_dir($this->enableDir)) {
throw new NotReadableError( throw new NotReadableError(