From 310a5f8d7a583b76b4bb103a2fd16fb47dd820df Mon Sep 17 00:00:00 2001 From: Victor Bojica Date: Thu, 6 Feb 2025 11:29:10 +0200 Subject: [PATCH] fix email changes --- lib/ts/recipe/webauthn/recipeImplementation.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/lib/ts/recipe/webauthn/recipeImplementation.ts b/lib/ts/recipe/webauthn/recipeImplementation.ts index 005fdaac2..018fefd1f 100644 --- a/lib/ts/recipe/webauthn/recipeImplementation.ts +++ b/lib/ts/recipe/webauthn/recipeImplementation.ts @@ -45,13 +45,7 @@ export default function getRecipeInterface( const user = result.user as User; // todo this might be wrong but will have to figure out - what happens when there are multiple webauthn login methods ? - const parsedEmail = user.loginMethods.find((lm) => lm.recipeId === "webauthn")?.email; - if (!parsedEmail) { - return { - status: "RECOVER_ACCOUNT_TOKEN_INVALID_ERROR", - }; - } - email = parsedEmail; + email = user.loginMethods.find((lm) => lm.recipeId === "webauthn")?.email; } if (!email) {