From 61fc6ea9dcdcbf5454ad85cae32120c9d5d4c8b4 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Wed, 21 Dec 2022 14:12:36 +0100 Subject: Oops. Fix change password bug. --- server.js | 1 + 1 file changed, 1 insertion(+) diff --git a/server.js b/server.js index 8ba605f..380e14d 100644 --- a/server.js +++ b/server.js @@ -537,6 +537,7 @@ app.post('/change-password', must_be_logged_in, function (req, res) { return res.render('change_password.pug', { user: req.user, flash: "Wrong password!" }) let salt = crypto.randomBytes(32).toString('hex') let hash = hash_password(newpass, salt) + SQL_UPDATE_USER_PASSWORD.run(hash, salt, user.user_id) return res.redirect('/profile') }) -- cgit v1.2.3