From cbfa126eeb596ec389957a6b30fba4025844ca02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20K=C3=B6rner?= Date: Wed, 22 Feb 2023 13:46:38 +0100 Subject: [PATCH] fixed invalid syntax --- CHANGELOG.md | 3 +++ library/Haste/Cache/FileCache.php | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2008625..d861bab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,9 @@ All notable changes to this project will be documented in this file. +## [1.15.13] - 2023-02-22 +- Fixed: invalid syntax + ## [1.15.12] - 2023-01-09 - Changed: allow phpfastcache 7 for usage in projects with php 8 - Changed: adapt usage of phpfastcache to work with the new version diff --git a/library/Haste/Cache/FileCache.php b/library/Haste/Cache/FileCache.php index d3837f6..a08128c 100644 --- a/library/Haste/Cache/FileCache.php +++ b/library/Haste/Cache/FileCache.php @@ -18,8 +18,12 @@ class FileCache extends Cache protected static $driver = 'files'; - protected static function extendOptions($config = new ConfigurationOption): ConfigurationOption + protected static function extendOptions($config = null): ConfigurationOption { + if (!$config) { + $config = new ConfigurationOption(); + } + $filename = TL_ROOT . '/' . ltrim(self::$cacheDir, '/'); if (!is_dir($filename)) {