From 24ce396c336f24719d5b6b7b242ed6033631a5d6 Mon Sep 17 00:00:00 2001 From: Gabriel Soullier Date: Wed, 8 Jun 2022 17:47:24 +0200 Subject: [PATCH] make cache ttl compatible with Symfony --- src/Adaptors/FirebasePhpJwt.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Adaptors/FirebasePhpJwt.php b/src/Adaptors/FirebasePhpJwt.php index a3c723a..d93a790 100644 --- a/src/Adaptors/FirebasePhpJwt.php +++ b/src/Adaptors/FirebasePhpJwt.php @@ -67,7 +67,7 @@ public function getKeys(string $jku): array } $keys = json_decode($this->request->setUrl($jku)->get()->getBody()->getContents()); - $this->cache->set($cacheKey, $keys, Carbon::now()->addDay()); + $this->cache->set($cacheKey, $keys, Carbon::now()->addDay()->diffInRealSeconds()); return self::parseKeySet($keys); }