Skip to content

Commit

Permalink
cleanup, show error
Browse files Browse the repository at this point in the history
  • Loading branch information
peintnermax committed Aug 2, 2023
1 parent 4cb618f commit 3b7e150
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
7 changes: 2 additions & 5 deletions apps/login/app/(login)/register/idp/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,10 @@ function getIdentityProviders(
});
}

export default async function Page({
searchParams,
}: {
searchParams: Record<string | number | symbol, string | undefined>;
}) {
export default async function Page() {
const legal = await getLegalAndSupportSettings(server);

// TODO if org idps should be shown replace emptystring with the orgId.
const identityProviders = await getIdentityProviders(server, "");

const host = process.env.VERCEL_URL
Expand Down
6 changes: 6 additions & 0 deletions apps/login/ui/SignInWithIDP.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
} from "@zitadel/react";
import { useRouter } from "next/navigation";
import { ProviderSlug } from "#/lib/demos";
import Alert from "./Alert";

export interface SignInWithIDPProps {
children?: ReactNode;
Expand Down Expand Up @@ -117,6 +118,11 @@ export function SignInWithIDP({
return null;
}
})}
{error && (
<div className="py-4">
<Alert>{error}</Alert>
</div>
)}
</div>
);
}
Expand Down

0 comments on commit 3b7e150

Please sign in to comment.