Bootstrap: Only replace config dir with its canonicalised absolute pathname when the dir exists

This commit is contained in:
Alexander Klimov 2014-06-25 11:53:55 +02:00
parent 5974305647
commit 53de3686a8
1 changed files with 2 additions and 4 deletions

View File

@ -151,10 +151,8 @@ abstract class ApplicationBootstrap
$configDir = '/etc/icingaweb';
}
}
$this->configDir = realpath($configDir);
if (!$this->configDir) {
$this->configDir = '/etc/icingaweb';
}
$canonical = realpath($configDir);
$this->configDir = $canonical ? $canonical : $configDir;
$this->setupAutoloader();
$this->setupZendAutoloader();