UPDATE: Almost fully implemented forget email feature

This commit is contained in:
JustIceO7
2025-02-06 19:30:37 +00:00
parent 00d627a1e2
commit bb67f13417
7 changed files with 63 additions and 52 deletions

View File

@@ -28,7 +28,7 @@ const PasswordResetForm: React.FC<SubmitProps> = ({ onSubmit, token }) => {
});
const confirmPasswordReset = () => {
alert('Password reset successfully!');
alert(`${resetData.newPassword} - ${token}`);
// You can replace this with navigation or API success handling logic
};
@@ -64,7 +64,7 @@ const PasswordResetForm: React.FC<SubmitProps> = ({ onSubmit, token }) => {
if (validateResetForm()) {
try {
const response = await fetch("/user/reset_password/<string:${token}", {
const response = await fetch(`/api/user/reset_password/${token}/${resetData.newPassword}`, {
method: "POST",
headers: {
"Content-Type": "application/json",