Do not redirect to logout after login

This can happen when the session was killed due to a timeout. Then
logout was triggered. Nobody wants to login only to be logged out again.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2021-01-15 09:29:54 +01:00
parent c80e007607
commit f57b93098b
No known key found for this signature in database
GPG Key ID: F941078878347C0C
1 changed files with 4 additions and 1 deletions

View File

@ -175,8 +175,11 @@ class LoginController extends Controller {
);
if (!empty($redirect_url)) {
[$url, ] = explode('?', $redirect_url);
if ($url !== $this->urlGenerator->linkToRoute('core.login.logout')) {
$this->initialStateService->provideInitialState('core', 'loginRedirectUrl', $redirect_url);
}
}
$this->initialStateService->provideInitialState(
'core',