fix: update should be based on email only (#9977)

This commit is contained in:
Alex van Andel authored and GitHub committed 2023-07-06 23:55:00 +00:00
1 parent f07c0b09fa
commit afd41475c9
1 file changed
+1 -4
@@ -616,10 +616,7 @@ export const AUTH_OPTIONS: AuthOptions = {
) {
await prisma.user.update({
where: {
email_username: {
email: existingUserWithEmail.email,
username: existingUserWithEmail.username!,
},
email: existingUserWithEmail.email,
},
data: {
// update the email to the IdP email