misc: moved user lock reset after backup success

This commit is contained in:
Sheen Capadngan
2024-05-24 23:56:24 +08:00
parent c0daa11aeb
commit b9a6f94eea
@@ -138,11 +138,6 @@ export const authPaswordServiceFactory = ({
code code
}); });
await userDAL.updateById(user.id, {
isLocked: false,
temporaryLockDateEnd: null
});
const token = jwt.sign( const token = jwt.sign(
{ {
authTokenType: AuthTokenType.SIGNUP_TOKEN, authTokenType: AuthTokenType.SIGNUP_TOKEN,
@@ -179,6 +174,12 @@ export const authPaswordServiceFactory = ({
salt, salt,
verifier verifier
}); });
await userDAL.updateById(userId, {
isLocked: false,
temporaryLockDateEnd: null,
consecutiveFailedMfaAttempts: 0
});
}; };
/* /*