When I try to authenticate using Github, I get a "User not found" message. #908
-
Although I set it up by looking at the GitHub of the guide at the following URL, When I press the GitHub authentication button, I am returned to the authentication page. At first I thought it was due to missing data in Upon checking, I noticed that the id was undefined. Am I doing something wrong around authentication at this time? Or is it possible that you made some mistake in your local environment? Sorry for my poor English and basic questions. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hey @motsuo373! Sorry for the slow response—this slipped through the cracks. I've just tried setting up a new starter kit app following the GitHub auth guide, and it's working okay for me. Have you modified any other code in the starter kit? If so, feel free to share any code so that we can help you fix it. The error you're getting suggests that Have you tried using a different browser or a different email? Bear in mind that the email must have a GitHub account linked to it. Feel free to share more info, and I'll try to help 🙂. |
Beta Was this translation helpful? Give feedback.
Hey @motsuo373! Sorry for the slow response—this slipped through the cracks. I've just tried setting up a new starter kit app following the GitHub auth guide, and it's working okay for me.
Have you modified any other code in the starter kit? If so, feel free to share any code so that we can help you fix it. The error you're getting suggests that
session.user.email
isundefined
on this line. This is a NextAuth callback, anduser.email
should not be undefined.Have you tried using a different browser or a different email? Bear in mind that the email must have a GitHub account linked to it. Feel free to share more info, and I'll try to help 🙂.