[breaking] mapProfileToUser gets called twice when logging in via ID Tokens, breaking authentication
Hi,
mapProfileToUser
seems to be getting called twice when logging in via Social Provider ID Tokens.
By putting a logger.info();
in the provider mapProfileToUser
, you can see that it logs two values, the first being the actual response from the provider, the second one being the Better Auth user object. This leads to the UNABLE_TO_CREATE_USER
error due to the fact that the second response does not contain provider-native arguments such as profile.given_name
0 Replies