Your question
How do I edit the user object received from say Google provider BEFORE it is saved to my DB. I use MongoDB.
What are you trying to do
Story
- User clicks Sign in with Google on my Next.js app using next-auth
- Add a
username property to the user object returned by Google
- User is redirected to "/profile/${username}"
- I check my MongoDB and find the new user's information including the property I added (i.e username field) BEFORE the user is saved to my DB.
Reproduction
NA
Feedback
Documentation refers to searching through online documentation, code comments and issue history. The example project refers to next-auth-example.