mirror of
https://github.com/fosrl/pangolin.git
synced 2026-02-14 17:06:39 +00:00
improve clean redirects
This commit is contained in:
@@ -15,6 +15,7 @@ import {
|
||||
useSearchParams
|
||||
} from "next/navigation";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { cleanRedirect } from "@app/lib/cleanRedirect";
|
||||
|
||||
export type LoginFormIDP = {
|
||||
idpId: number;
|
||||
@@ -63,9 +64,10 @@ export default function IdpLoginButtons({
|
||||
redirect || "/",
|
||||
orgId
|
||||
);
|
||||
const safeRedirect = cleanRedirect(redirect || "/");
|
||||
const response = await generateOidcUrlProxy(
|
||||
idpId,
|
||||
redirect || "/",
|
||||
safeRedirect,
|
||||
orgId
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user