Skip to content

Commit

Permalink
MODADMIN-46 Фикс в редактировании пользователя
Browse files Browse the repository at this point in the history
  • Loading branch information
Данил Колесник committed Apr 28, 2020
1 parent 1f5061d commit c7a920c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/.idea/*
/.git/*
/node_modules/*
/view/node_modules/*
/view/static/node_modules/*
/view/vendor/*
/view/static/vendor/*
/view/static/css/*.less.css
Expand Down
2 changes: 1 addition & 1 deletion models/security/user.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ module.exports = (getScope) => {
delete data.login;
}
data.disabled = Boolean(data.disabled);
data.needPwdReset = true;

let p0 = Promise.resolve();
if (data.pwd) {
p0 = getAccounts().setPassword(id, null, data.pwd);
data.needPwdReset = true;
delete data.pwd;
}
return p0.then(() => getAccounts().set(id, data))
Expand Down

0 comments on commit c7a920c

Please sign in to comment.