We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eae33cd commit 546dc8bCopy full SHA for 546dc8b
{{cookiecutter.project_slug}}/backend/app/app/api/api_v1/endpoints/login.py
@@ -1,6 +1,6 @@
1
from datetime import timedelta
2
3
-from fastapi import APIRouter, Depends, HTTPException
+from fastapi import APIRouter, Body, Depends, HTTPException
4
from fastapi.security import OAuth2PasswordRequestForm
5
from sqlalchemy.orm import Session
6
@@ -74,7 +74,7 @@ def recover_password(email: str, db: Session = Depends(get_db)):
74
75
76
@router.post("/reset-password/", tags=["login"], response_model=Msg)
77
-def reset_password(token: str, new_password: str, db: Session = Depends(get_db)):
+def reset_password(token: str, new_password: str = Body(...), db: Session = Depends(get_db)):
78
"""
79
Reset password
80
0 commit comments