You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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.
This discussion was converted from issue #1348 on February 21, 2021 18:49.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
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
username
property to theuser
object returned by GoogleReproduction
NA
Feedback
Documentation refers to searching through online documentation, code comments and issue history. The example project refers to next-auth-example.
Beta Was this translation helpful? Give feedback.
All reactions