From 34416ad804bbd2c6d2746714dc406f76835aff32 Mon Sep 17 00:00:00 2001 From: ben Date: Tue, 18 Aug 2026 17:31:17 +0200 Subject: [PATCH] update --- backend/main.py | 52 ++++++++++++++++++++++++++++++++++--------------- 1 file changed, 36 insertions(+), 16 deletions(-) diff --git a/backend/main.py b/backend/main.py index 1647d73..699c5fe 100644 --- a/backend/main.py +++ b/backend/main.py @@ -1139,26 +1139,46 @@ def api_forgot_password( ): return reset_password(data.email) -@app.post( +@app.get( "/update-password", - summary="Reset password with token", - description="Sets a new password using a password reset token.", + response_class=HTMLResponse, ) -def api_update_password( - data: PasswordReset, -): - result = reset_password_with_token( - data.token, - data.new_password, - ) +def update_password_page(token: str = Query(...)): + return f""" + + + + + + Reset password + + +

Reset password

- if result["status"] == "failed": - raise HTTPException( - status_code=400, - detail=result["reason"], - ) +
+ - return result + + + +
+ + + """ # easter egg