Cleanup root folder (fixes #110)

This commit is contained in:
Pierre Rudloff 2017-05-15 07:25:14 +02:00
parent c1c6c2dd97
commit f9203706f7
21 changed files with 17 additions and 17 deletions

View file

@ -126,13 +126,13 @@ class Config
*
* @return Config
*/
public static function getInstance($yamlfile = 'config.yml')
public static function getInstance($yamlfile = 'config/config.yml')
{
$yamlPath = __DIR__.'/../'.$yamlfile;
if (is_null(self::$instance) || self::$instance->file != $yamlfile) {
if (is_file($yamlfile)) {
$options = Yaml::parse(file_get_contents($yamlPath));
} elseif ($yamlfile == 'config.yml' || empty($yamlfile)) {
} elseif ($yamlfile == 'config/config.yml' || empty($yamlfile)) {
/*
Allow for the default file to be missing in order to
not surprise users that did not create a config file