Replies: 1 comment
-
next-auth uses the ID provided by the OAuth provider, not the email address, to determine if the accounts are identical. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm using the GitLab OAuth provider with a database adapter and JWT session strategy.
Version: 5.0.0-beta.22
On the first sign in everything works flawlessly and the user and linked gitlab account are created.
However on subsequent sign ins (sign out and sign in again) next-auth throws the error
OAuthAccountNotLinked: Another account already exists with the same e-mail address.
.If I'm understanding the docs correctly, this error should only be thrown if the user is trying to sign in with an account not already linked to it. But in my case it is thrown when signin in with the same (already linked) provider account.
Am I misunderstanding something?
Beta Was this translation helpful? Give feedback.
All reactions