mirror of
https://github.com/khoj-ai/khoj.git
synced 2024-11-27 17:35:07 +01:00
Fix return type of the update_or_create method
This commit is contained in:
parent
992e54c218
commit
4a487aff23
1 changed files with 1 additions and 1 deletions
|
@ -80,7 +80,7 @@ async def get_or_create_user(token: dict) -> KhojUser:
|
|||
|
||||
|
||||
async def create_user_by_token(token: dict) -> KhojUser:
|
||||
user = await KhojUser.objects.filter(email=token.get("email")).aupdate_or_create(
|
||||
user, _ = await KhojUser.objects.filter(email=token.get("email")).aupdate_or_create(
|
||||
defaults={"username": token.get("email"), "email": token.get("email")}
|
||||
)
|
||||
await user.asave()
|
||||
|
|
Loading…
Reference in a new issue