enh: remove token cookie on signout

This commit is contained in:
Timothy J. Baek
2024-10-24 13:35:29 -07:00
parent 6b620d93a9
commit e9e49babf8
3 changed files with 34 additions and 1 deletions

View File

@@ -323,6 +323,12 @@ async def signup(request: Request, response: Response, form_data: SignupForm):
raise HTTPException(500, detail=ERROR_MESSAGES.DEFAULT(err))
@router.get("/signout")
async def signout(response: Response):
response.delete_cookie("token")
return {"status": True}
############################
# AddUser
############################