Skip to content

Commit 6a785d9

Browse files
Merge branch '5.0' into 5.1
* 5.0: Fix abstract method name in PHP doc block Various cleanups [HttpClient] fix issues in tests Fixes sprintf(): Too few arguments in form transformer [Console] Fix QuestionHelper::disableStty() [Validator] Use Mime component to determine mime type for file validator validate subforms in all validation groups Update Hungarian translations Add meaningful message when Process is not installed (ProcessHelper) [PropertyAccess] Fix TypeError parsing again. [TwigBridge] fix fallback html-to-txt body converter [Security/Http] fix merge [ErrorHandler] fix setting $trace to null in FatalError [Form] add missing Czech validators translation [Validator] add missing Czech translations never directly validate Existence (Required/Optional) constraints
2 parents 932d473 + e18913e commit 6a785d9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Firewall/ExceptionListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ private function handleAccessDeniedException(ExceptionEvent $event, AccessDenied
185185

186186
private function handleLogoutException(ExceptionEvent $event, LogoutException $exception): void
187187
{
188-
$event->setException(new AccessDeniedHttpException($exception->getMessage(), $exception));
188+
$event->setThrowable(new AccessDeniedHttpException($exception->getMessage(), $exception));
189189

190190
if (null !== $this->logger) {
191191
$this->logger->info('A LogoutException was thrown; wrapping with AccessDeniedHttpException', ['exception' => $exception]);

Tests/Firewall/ExceptionListenerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,8 @@ public function testLogoutException()
165165
$listener = $this->createExceptionListener();
166166
$listener->onKernelException($event);
167167

168-
$this->assertEquals('Invalid CSRF.', $event->getException()->getMessage());
169-
$this->assertEquals(403, $event->getException()->getStatusCode());
168+
$this->assertEquals('Invalid CSRF.', $event->getThrowable()->getMessage());
169+
$this->assertEquals(403, $event->getThrowable()->getStatusCode());
170170
}
171171

172172
public function getAccessDeniedExceptionProvider()

0 commit comments

Comments
 (0)