From ca6515cc76a57a39f63807e3cdc83ab7932a6af9 Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Fri, 4 Oct 2019 10:02:16 +0200 Subject: [PATCH] [Cache] fix logger usage in CacheTrait::doGet() --- src/Symfony/Contracts/Cache/CacheTrait.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Symfony/Contracts/Cache/CacheTrait.php b/src/Symfony/Contracts/Cache/CacheTrait.php index 7bbdef087e..355ea2962e 100644 --- a/src/Symfony/Contracts/Cache/CacheTrait.php +++ b/src/Symfony/Contracts/Cache/CacheTrait.php @@ -56,7 +56,7 @@ trait CacheTrait if ($recompute = $ctime && $expiry && $expiry <= ($now = microtime(true)) - $ctime / 1000 * $beta * log(random_int(1, PHP_INT_MAX) / PHP_INT_MAX)) { // force applying defaultLifetime to expiry $item->expiresAt(null); - $this->logger && $this->logger->info('Item "{key}" elected for early recomputation {delta}s before its expiration', [ + $logger && $logger->info('Item "{key}" elected for early recomputation {delta}s before its expiration', [ 'key' => $key, 'delta' => sprintf('%.1f', $expiry - $now), ]);