fix: clear target path when canceling booking flow

This commit is contained in:
Björn Fromme
2025-11-25 17:34:10 +01:00
parent f5f5d43ab5
commit 9167c84b4c
@@ -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.');