mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
chore: remove setting AURLANG and AURTZ on login
We don't need to set these cookies when logging in. These settings are saved to the DB anyways. (and they are picked up from there as well for any web requests, when no cookies are given) Signed-off-by: moson-mo <mo-son@mailbox.org>
This commit is contained in:
parent
edc4ac332d
commit
638ca7b1d0
1 changed files with 1 additions and 15 deletions
|
@ -85,20 +85,6 @@ async def login_post(
|
|||
httponly=secure,
|
||||
samesite=cookies.samesite(),
|
||||
)
|
||||
response.set_cookie(
|
||||
"AURTZ",
|
||||
user.Timezone,
|
||||
secure=secure,
|
||||
httponly=secure,
|
||||
samesite=cookies.samesite(),
|
||||
)
|
||||
response.set_cookie(
|
||||
"AURLANG",
|
||||
user.LangPreference,
|
||||
secure=secure,
|
||||
httponly=secure,
|
||||
samesite=cookies.samesite(),
|
||||
)
|
||||
response.set_cookie(
|
||||
"AURREMEMBER",
|
||||
remember_me,
|
||||
|
@ -125,5 +111,5 @@ async def logout(request: Request, next: str = Form(default="/")):
|
|||
# to redirect to a get request.
|
||||
response = RedirectResponse(url=next, status_code=HTTPStatus.SEE_OTHER)
|
||||
response.delete_cookie("AURSID")
|
||||
response.delete_cookie("AURTZ")
|
||||
response.delete_cookie("AURREMEMBER")
|
||||
return response
|
||||
|
|
Loading…
Add table
Reference in a new issue