Move OIDC login page to /auth/wiki-login to avoid catch-all conflict
The /oidc/[...] server catch-all was intercepting /oidc/login before the Nuxt page router could render it. Moving the page outside /oidc/ avoids the conflict entirely.
This commit is contained in:
parent
3187b5118b
commit
4b3fed9689
3 changed files with 1 additions and 7 deletions
|
|
@ -11,12 +11,6 @@
|
|||
import { getOidcProvider } from "../../utils/oidc-provider.js";
|
||||
|
||||
export default defineEventHandler(async (event) => {
|
||||
// Let Nuxt handle the /oidc/login page (Vue SPA route)
|
||||
const path = event.path || getRequestURL(event).pathname;
|
||||
if (path === "/oidc/login" || path.startsWith("/oidc/login?")) {
|
||||
return;
|
||||
}
|
||||
|
||||
const provider = await getOidcProvider();
|
||||
const { req, res } = event.node;
|
||||
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ export default defineEventHandler(async (event) => {
|
|||
}
|
||||
|
||||
// No valid session — redirect to login page
|
||||
return sendRedirect(event, `/oidc/login?uid=${uid}`, 302);
|
||||
return sendRedirect(event, `/auth/wiki-login?uid=${uid}`, 302);
|
||||
}
|
||||
|
||||
// ----- Consent prompt -----
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue