diff options
author | Tor Andersson <tor@ccxvii.net> | 2022-01-07 11:58:17 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2022-01-07 13:10:51 +0100 |
commit | 91c4271226baa226c059860b5cf655a268ebd1e2 (patch) | |
tree | 8afb0e68f05d4b5c65b642732cdd731a43c1e1ac | |
parent | 36d047d337db428b54c1d7663ca0e29ee16e5c6a (diff) | |
download | server-91c4271226baa226c059860b5cf655a268ebd1e2.tar.gz |
Fix password reset token.
-rw-r--r-- | server.js | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -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); |