diff options
author | 2019-03-02 19:33:33 +0100 | |
---|---|---|
committer | 2019-03-02 19:33:44 +0100 | |
commit | f450b2e1186dd14a9b47e703c39ade608306945c (patch) | |
tree | e185fbb03c90f701289657cef6168b4c3aefcc71 /caches/SQLiteCache.php | |
parent | 688c950916d79deb6f400816b9e8f011cf0c5381 (diff) | |
download | rss-bridge-f450b2e1186dd14a9b47e703c39ade608306945c.tar.gz rss-bridge-f450b2e1186dd14a9b47e703c39ade608306945c.tar.zst rss-bridge-f450b2e1186dd14a9b47e703c39ade608306945c.zip |
[SQLiteCache] Check sqlite3 extension in __construct
Checks if the sqlite3 extension is loaded and throws an error
if it's missing.
Diffstat (limited to 'caches/SQLiteCache.php')
-rw-r--r-- | caches/SQLiteCache.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/caches/SQLiteCache.php b/caches/SQLiteCache.php index b3caac34..5cbb3772 100644 --- a/caches/SQLiteCache.php +++ b/caches/SQLiteCache.php @@ -9,6 +9,9 @@ class SQLiteCache implements CacheInterface { private $db = null; public function __construct() { + if (!extension_loaded('sqlite3')) + die('"sqlite3" extension not loaded. Please check "php.ini"'); + $file = PATH_CACHE . 'cache.sqlite'; if (!is_file($file)) { |