dever 4 gadi atpakaļ
vecāks
revīzija
f3c6990e08
1 mainītis faili ar 5 papildinājumiem un 1 dzēšanām
  1. 5 1
      lib/Config.php

+ 5 - 1
lib/Config.php

@@ -12,7 +12,11 @@ class Config
 
     protected function import()
     {
-        $config = include($this->file());
+        $file = $this->file();
+        if (!is_file($file)) {
+            $this->create();
+        }
+        $config = include($file);
         return $config;
     }