Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Database | Updated values not being applied when I sign out and back in. #3242

Closed
callumok2004 opened this issue Nov 20, 2021 · 1 comment
Closed
Labels
bug Something isn't working

Comments

@callumok2004
Copy link

callumok2004 commented Nov 20, 2021

Description 🐜

When I sign in, let's say the avatar given by discord is abcdef then I change it, log out and back in, now the avatar given is abcdef123, I log the response given by the API and it shows the correct value, but the database and session does not update with the new values. This is the same for username, banner etc.

Is this a bug in your own project?

Yes

How to reproduce ☕️

https://github.com/callumok2004/nextjs-reproduction/blob/main/src/pages/api/auth/%5B...nextauth%5D.ts

Screenshots / Logs 📽

image

Environment 🖥

N/A, Windows 11 removes WMIC which the below command depends on.

Contributing 🙌🏽

No, I am afraid I cannot help regarding this

@callumok2004 callumok2004 added the bug Something isn't working label Nov 20, 2021
@balazsorban44
Copy link
Member

balazsorban44 commented Nov 20, 2021

we don't update the user on signing in the second time currently. there are plans to provide an easier way to update the user in the future. follow #2269

for now, you will have to make sure the database is updated yourself. events might be the best place for this https://next-auth.js.org/configuration/events

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants