From 59242f16cd4ced789b576ec41cfe586c79895055 Mon Sep 17 00:00:00 2001 From: joostdecock Date: Sun, 13 Aug 2023 10:51:44 +0200 Subject: [PATCH] fix(backen): Incorrect refactor --- sites/backend/src/models/user.mjs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sites/backend/src/models/user.mjs b/sites/backend/src/models/user.mjs index fafb00d0ce3..b3e56941d0b 100644 --- a/sites/backend/src/models/user.mjs +++ b/sites/backend/src/models/user.mjs @@ -461,10 +461,7 @@ UserModel.prototype.passwordSignIn = async function (req) { * have their password and we know it's good, let's rehash it the v3 way * if this happens to be a v2 user. */ - if (updatedPasswordField) { - update.password = updatedPasswordField - await this.update(update) - } + if (updatedPasswordField) await this.update({ password: updatedPasswordField }) /* * Final check for account status and other things before returning