fix: passwords always expiring upon login

v1.18.x
Julian Lam 5 years ago
parent ca3be1f336
commit ddf3812cdc

@ -371,7 +371,7 @@ authenticationController.localLogin = async function (req, username, password, n
const uid = await user.getUidByUserslug(userslug);
try {
const [userData, isAdminOrGlobalMod, banned, hasLoginPrivilege] = await Promise.all([
db.getObjectFields('user:' + uid, ['uid', 'passwordExpiry']),
user.getUserFields(uid, ['uid', 'passwordExpiry']),
user.isAdminOrGlobalMod(uid),
user.bans.isBanned(uid),
privileges.global.can('local:login', uid),

Loading…
Cancel
Save