fix(sso): one more (#4028)

This commit is contained in:
Chuck Driesler
2025-02-19 11:32:14 +00:00
committed by GitHub
parent fdbc05a942
commit b5c8e90937
@@ -686,7 +686,7 @@ const tryGetSpeckleUserDataFactory =
// Get user with email that matches OIDC provider user email, if match exists
const providerEmail = getEmailFromOidcProfile(oidcProviderUserData)
const userEmail = await findEmail({ email: providerEmail })
const userEmail = await findEmail({ email: providerEmail.toLowerCase() })
if (!!userEmail && !userEmail.verified) throw new SsoUserEmailUnverifiedError()
const existingSpeckleUser = await getUser(userEmail?.userId ?? '')