diff --git a/src/FuzeWorks/ObjectStorage/ObjectStorageCache.php b/src/FuzeWorks/ObjectStorage/ObjectStorageCache.php index e4822f2..02e59ae 100644 --- a/src/FuzeWorks/ObjectStorage/ObjectStorageCache.php +++ b/src/FuzeWorks/ObjectStorage/ObjectStorageCache.php @@ -49,7 +49,7 @@ class ObjectStorageCache implements CacheInterface private function testTTL(string $key) { $meta = $this->provider->getItemMeta('fwcache_' . $key); - if ($meta['ttl'] > 0 && time() > $meta['time'] + $meta['ttl']) + if (!is_null($meta) && $meta['ttl'] > 0 && time() > $meta['time'] + $meta['ttl']) $this->provider->deleteItem('fwcache_' . $key); }