Commit ce8bca70 authored by Stephane Bouvry's avatar Stephane Bouvry
Browse files

Fix : Erreur liée à la récupération des configurations éditable quand le fichier est vide.

parent 64ceb72d
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -156,12 +156,14 @@ class AbstractOscarController extends AbstractActionController implements UseOsc
    protected function getEditableConfRoot(){
        $path = $this->getYamlConfigPath();
        if( file_exists($path) ) {
            $contentFile = file_get_contents($path);
            if ($contentFile) {
                $parser = new Parser();
                return $parser->parse(file_get_contents($path));
        } else {
            return [];
            }
        }
        return [];
    }

    protected function getEditableConfKey($key, $default = null){
        $conf = $this->getEditableConfRoot();