Skip to content

Commit

Permalink
Use given_name and family_name
Browse files Browse the repository at this point in the history
  • Loading branch information
CannonLock committed Aug 7, 2024
1 parent 41ac69c commit 168b595
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/routes/security.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ async def redirect_callback(code: str, state: Optional[str] = None):
user = await get_user(user_data['sub'])

if user is None:
user = await create_user(user_data['sub'], user_data.get('name', ''), user_data.get('email', ''))
user = await create_user(user_data['sub'], user_data.get('given_name', '') + user_data.get('family_name', ''), user_data.get('email', ''))

access_token = create_access_token(
data={
Expand Down

0 comments on commit 168b595

Please sign in to comment.