diff --git a/api/src/accounts/account.service.js b/api/src/accounts/account.service.js index 72608d6..8b57aec 100644 --- a/api/src/accounts/account.service.js +++ b/api/src/accounts/account.service.js @@ -93,6 +93,12 @@ async function resetPassword({ token, password }) { // update password and remove reset token account.setPassword(password); account.resetToken = undefined; + + // Since password recovery happens through email, we can consider this a + // successful verification of the email address. + account.needsEmailValidation = false; + account.verificationToken = undefined; + await account.save(); }