Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 172862c

Browse files
committed
fix rendering exception pages without the HttpKernel component
1 parent cb1aaf5 commit 172862c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/ErrorHandler/ErrorRenderer/HtmlErrorRenderer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ private function renderException(FlattenException $exception, string $debugTempl
140140
'exceptionMessage' => $exceptionMessage,
141141
'statusText' => $statusText,
142142
'statusCode' => $statusCode,
143-
'logger' => DebugLoggerConfigurator::getDebugLogger($this->logger),
143+
'logger' => null !== $this->logger && class_exists(DebugLoggerConfigurator::class) ? DebugLoggerConfigurator::getDebugLogger($this->logger) : null,
144144
'currentContent' => \is_string($this->outputBuffer) ? $this->outputBuffer : ($this->outputBuffer)(),
145145
]);
146146
}

0 commit comments

Comments
 (0)