UPDATE: Added util functions for handling streaming routes

This commit is contained in:
JustIceO7
2025-01-29 03:04:56 +00:00
parent 46c7ca3f10
commit 95827ccf95
3 changed files with 70 additions and 12 deletions

View File

@@ -126,10 +126,10 @@ def reset_password(new_password: str, email: str):
Given email and new password reset the password for a given user
"""
db = Database()
cursor = db.create_connection()
db.create_connection()
try:
cursor.execute("UPDATE users SET password = ? WHERE email = ?", (generate_password_hash(new_password), email))
db.execute("UPDATE users SET password = ? WHERE email = ?", (generate_password_hash(new_password), email))
db.commit()
return True
except Exception as e: