From c6a3d0da52a2ed13ec70f78eb81cce732d26f571 Mon Sep 17 00:00:00 2001 From: mrjvs Date: Sun, 25 Oct 2026 11:57:46 +0100 Subject: [PATCH] fix: resolve issue where discourse redirects dont work --- src/composables/useAuthUtils.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/composables/useAuthUtils.ts b/src/composables/useAuthUtils.ts index 75e1df8..46a4ec5 100644 --- a/src/composables/useAuthUtils.ts +++ b/src/composables/useAuthUtils.ts @@ -16,8 +16,9 @@ export function getSafeRedirectUrl(input: string | null, baseUrl: string, allowe return null; // Not in the allowed hosts } - // If on the same host as the website, only return the path. For internal redirects - if (url.host === parsedBaseUrl.host) { + // If on the same host as the website, only return the path. For internal redirects (cuz they load faster) + // Exception: SSO urls are routes and not pages, cant be an internal redirect + if (url.host === parsedBaseUrl.host && !url.pathname.includes('sso')) { return { url: url.pathname + url.search, external: false