From c0aaa15ad5d4efeadd090eb407d3645e324cbb1c Mon Sep 17 00:00:00 2001 From: Fred Tempez Date: Fri, 18 Sep 2020 04:10:13 +0200 Subject: [PATCH] =?UTF-8?q?jsonDb=20supprimer=20init=20mod=C3=A8le=20donn?= =?UTF-8?q?=C3=A9es?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/class/jsondb/JsonDb.class.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/class/jsondb/JsonDb.class.php b/core/class/jsondb/JsonDb.class.php index 41ab795c..eae524f6 100644 --- a/core/class/jsondb/JsonDb.class.php +++ b/core/class/jsondb/JsonDb.class.php @@ -101,6 +101,7 @@ class JsonDb extends \Prowebcraft\Dot protected function loadData($reload = false) { if ($this->data === null || $reload) { $this->db = $this->config['dir'] . DIRECTORY_SEPARATOR . $this->config['name']; + /* if (!file_exists($this->db)) { $templateFile = $this->config['template']; if (file_exists($templateFile)) { @@ -117,6 +118,7 @@ class JsonDb extends \Prowebcraft\Dot } } } + */ $this->data = json_decode(file_get_contents($this->db), true); if (!$this->data === null) { throw new \InvalidArgumentException('Database file ' . $this->db