[PR #5894] fix(oauth2): fix user data not reflecting provider updates with overrideUserInfo #14550

Closed
opened 2026-04-13 09:31:35 -05:00 by GiteaMirror · 0 comments
Owner

Original Pull Request: https://github.com/better-auth/better-auth/pull/5894

State: closed
Merged: Yes


When overrideUserInfo is enabled, updateUser() was called but its return value wasn't captured, causing sessions to be created with stale user data instead of the updated information from the OAuth provider.


Summary by cubic

Fixed OAuth sessions using stale user data when overrideUserInfo is enabled. We now assign the result of updateUser to the user object so sessions reflect provider updates on sign-in and account linking.

Written for commit ac9664c3b2. Summary will update automatically on new commits.

**Original Pull Request:** https://github.com/better-auth/better-auth/pull/5894 **State:** closed **Merged:** Yes --- When `overrideUserInfo` is enabled, `updateUser()` was called but its return value wasn't captured, causing sessions to be created with stale user data instead of the updated information from the OAuth provider. <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Fixed OAuth sessions using stale user data when overrideUserInfo is enabled. We now assign the result of updateUser to the user object so sessions reflect provider updates on sign-in and account linking. <sup>Written for commit ac9664c3b26449d2da631327b5ff8aeabe16e7ed. Summary will update automatically on new commits.</sup> <!-- End of auto-generated description by cubic. -->
GiteaMirror added the pull-request label 2026-04-13 09:31:35 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#14550