[release-11.3.4] Auth: Fix redirect with JWT auth URL login (#100495)

Auth: Fix redirect with JWT auth URL login (#100295)

fix

(cherry picked from commit acc1521929)
This commit is contained in:
Misi
2025-02-12 20:25:00 +02:00
committed by GitHub
parent 7476d99bc7
commit ee2d0aac2a
+5
View File
@@ -390,6 +390,11 @@ function handleRedirectTo(): void {
const queryParams = locationService.getSearch();
const redirectToParamKey = 'redirectTo';
if (queryParams.has('auth_token')) {
// URL Login should not be redirected
window.sessionStorage.removeItem(RedirectToUrlKey);
}
if (queryParams.has(redirectToParamKey) && window.location.pathname !== '/') {
const rawRedirectTo = queryParams.get(redirectToParamKey)!;
window.sessionStorage.setItem(RedirectToUrlKey, encodeURIComponent(rawRedirectTo));