From 384daa62f4daef2ffead4dc6ab44fec3ca6f248b Mon Sep 17 00:00:00 2001 From: emkael Date: Wed, 14 Nov 2018 23:51:29 +0100 Subject: Not trying to access baord DB if it doesn't exist --- tdd/tdd-bootstrap.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tdd/tdd-bootstrap.php b/tdd/tdd-bootstrap.php index b1b89a9..551c9ed 100644 --- a/tdd/tdd-bootstrap.php +++ b/tdd/tdd-bootstrap.php @@ -261,7 +261,9 @@ class BoardDB { public function __construct($timestampFile = '.tdd-timestamps.cache', $dbFile = '.tdd-records.cache') { $this->__timestampFile = $timestampFile; $this->__dbFile = $dbFile; - $this->__database = unserialize(file_get_contents($this->__dbFile)); + if (file_exists($this->__dbFile)) { + $this->__database = unserialize(file_get_contents($this->__dbFile)); + } $this->refreshBoardDatabase(); } -- cgit v1.2.3