summaryrefslogtreecommitdiff
path: root/server.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2022-01-07 11:58:17 +0100
committerTor Andersson <tor@ccxvii.net>2022-01-07 13:10:51 +0100
commit91c4271226baa226c059860b5cf655a268ebd1e2 (patch)
tree8afb0e68f05d4b5c65b642732cdd731a43c1e1ac /server.js
parent36d047d337db428b54c1d7663ca0e29ee16e5c6a (diff)
downloadserver-91c4271226baa226c059860b5cf655a268ebd1e2.tar.gz
Fix password reset token.
Diffstat (limited to 'server.js')
-rw-r--r--server.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/server.js b/server.js
index be67657..5523541 100644
--- a/server.js
+++ b/server.js
@@ -376,7 +376,7 @@ app.post('/forgot-password', function (req, res) {
if (user) {
let token = SQL_FIND_TOKEN.get(user.user_id);
if (!token) {
- token = SQL_CREATE_TOKEN.run(user.user_id);
+ token = SQL_CREATE_TOKEN.get(user.user_id);
mail_password_reset_token(user, token);
}
return res.redirect('/reset-password/' + mail);