Skip to content

Commit

Permalink
hash on reset
Browse files Browse the repository at this point in the history
  • Loading branch information
ketertitus committed Mar 26, 2024
1 parent 8fc5b0e commit dbd1d42
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion reset.php
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,8 @@ function sendPasswordResetEmail($email, $resetToken)

// Prepare and bind the statement
$stmt = $conn->prepare($sql);
$stmt->bind_param("ss", $password, $rUID);
$hashedPassword = password_hash($password, PASSWORD_DEFAULT);
$stmt->bind_param("ss", $hashedPassword, $rUID);

// Prepare the SQL statement with a parameter placeholder
$sql1 = "SELECT `email`, `user_name` FROM user WHERE user_id = ?";
Expand Down

0 comments on commit dbd1d42

Please sign in to comment.