idp linking

This commit is contained in:
peintnermax
2024-07-23 13:58:43 +02:00
parent 505844d4c5
commit 82c57ae609
2 changed files with 1 additions and 3 deletions

View File

@@ -24,10 +24,8 @@ export default async function Page({
return retrieveIDPIntent(id, token)
.then((resp) => {
const { idpInformation, userId } = resp;
console.log("provider", provider, idpInformation, "userId", userId);
if (idpInformation) {
// handle login
if (userId) {
return (
<DynamicTheme branding={branding}>
@@ -44,7 +42,6 @@ export default async function Page({
</DynamicTheme>
);
} else {
// handle register
return createUser(provider, idpInformation)
.then((userId) => {
return (