From de07954fa12d3a37fb5e5aa88a9d224c02317d82 Mon Sep 17 00:00:00 2001 From: bnomei Date: Fri, 9 Aug 2024 20:34:57 +0200 Subject: [PATCH] :bug: default 60 sec for cache did not work (v3) Signed-off-by: bnomei --- classes/Blueprints/Blueprint.php | 4 ++-- composer.json | 2 +- vendor/composer/installed.php | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/classes/Blueprints/Blueprint.php b/classes/Blueprints/Blueprint.php index ddbe46e..5213a65 100644 --- a/classes/Blueprints/Blueprint.php +++ b/classes/Blueprints/Blueprint.php @@ -80,8 +80,8 @@ public function toArray(): array // some might not be cacheable like when they are class based and have dynamic fields // only set here now if they will not be written on __destruct by trait - // the cacha could be null which means it will use the default value - if (! in_array($this->cache, [false, 0]) && ! method_exists($this->modelClass, 'blueprintCacheKey')) { + // the cache could be null which means it will use the default value + if ($this->cache !== false && $this->cache !== 0 && ! method_exists($this->modelClass, 'blueprintCacheKey')) { BlueprintCache::set($key, $blueprint); } diff --git a/composer.json b/composer.json index 125134b..0c2fa20 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "bnomei/kirby-blueprints", "type": "kirby-plugin", - "version": "4.4.8", + "version": "4.4.9", "license": "MIT", "homepage": "https://github.com/bnomei/kirby3-blueprints", "description": "PHP Class-based Blueprints for Kirby CMS for better type safety and code completion", diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 08e9e5d..5290200 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -1,8 +1,8 @@ array( 'name' => 'bnomei/kirby-blueprints', - 'pretty_version' => '4.4.8', - 'version' => '4.4.8.0', + 'pretty_version' => '4.4.9', + 'version' => '4.4.9.0', 'reference' => null, 'type' => 'kirby-plugin', 'install_path' => __DIR__ . '/../../', @@ -11,8 +11,8 @@ ), 'versions' => array( 'bnomei/kirby-blueprints' => array( - 'pretty_version' => '4.4.8', - 'version' => '4.4.8.0', + 'pretty_version' => '4.4.9', + 'version' => '4.4.9.0', 'reference' => null, 'type' => 'kirby-plugin', 'install_path' => __DIR__ . '/../../',