full-stack-fastapi-template
full-stack-fastapi-template copied to clipboard
♻️ Simplify reset password logic by removing duplicate code
Description
This pull request refactors the reset_password API endpoint to delegate password hashing and database update logic to the existing crud.update_user method.
The original implementation in reset_password contained redundant code that is already handled in crud.py, resulting in unnecessary duplication.
This refactor aims to keep the password update process and database queries in one place (crud.py), making it easier to manage and update if needed.