diff --git a/src/JSONDB.php b/src/JSONDB.php index 6074412..8787389 100644 --- a/src/JSONDB.php +++ b/src/JSONDB.php @@ -104,7 +104,7 @@ private function check_file() } else { // Read content of JSON file $content = file_get_contents($this->file); - $content = json_decode(($content == '') ? '[]' : $content, true); + $content = json_decode($content, true); } // Check if its arrays of jSON