[HttpKernel] Don't cache "not-fresh" state
This commit is contained in:
parent
350e1100d5
commit
be80db3dc8
@ -514,8 +514,9 @@ abstract class Kernel implements KernelInterface, RebootableInterface, Terminabl
|
||||
|
||||
try {
|
||||
if (file_exists($cachePath) && \is_object($this->container = include $cachePath)
|
||||
&& (!$this->debug || (self::$freshCache[$k = $cachePath.'.'.$this->environment] ?? self::$freshCache[$k] = $cache->isFresh()))
|
||||
&& (!$this->debug || (self::$freshCache[$cachePath] ?? $cache->isFresh()))
|
||||
) {
|
||||
self::$freshCache[$cachePath] = true;
|
||||
$this->container->set('kernel', $this);
|
||||
error_reporting($errorLevel);
|
||||
|
||||
|
Reference in New Issue
Block a user