fix: clear target path when canceling booking flow

This commit is contained in:
Björn Fromme
2026-03-16 11:59:12 +01:00
parent f230b36382
commit 4db2cd7eda
@@ -116,6 +116,10 @@ class IndexController extends AbstractController
// Clear the booking session
$this->bookingService->clearBookingSession($request);
// Clear the security target path to prevent redirect loop after login
// Without this, logging in after cancel would redirect back to a stale booking URL
$request->getSession()->remove('_security.main.target_path');
// Add a flash message to inform the user
$this->addFlash('info', 'Buchung abgebrochen.');