From eaf54b28638e95925239b8f69bc67bdae2bfa531 Mon Sep 17 00:00:00 2001 From: Troplo Date: Fri, 12 Aug 2022 18:14:15 +1000 Subject: [PATCH] Update user.js --- backend/routes/user.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/routes/user.js b/backend/routes/user.js index 01d478d..c4056f3 100644 --- a/backend/routes/user.js +++ b/backend/routes/user.js @@ -511,7 +511,7 @@ router.put("/settings/:type", auth, async (req, res, next) => { id: req.user.id } }) - const match = await checkPasswordArgon2(req.body.current) + const match = await checkPasswordArgon2(req.body.current, user.password) if (match) { await user.update({ password: await argon2.hash(req.body.new)