Commit 21cfee12 authored by Junling Bu's avatar Junling Bu
Browse files

fix[litemall-admin-api]: 不能通过管理员编辑接口修改密码

parent aec557e9
......@@ -116,10 +116,8 @@ public class AdminAdminController {
return ResponseUtil.badArgument();
}
String rawPassword = admin.getPassword();
BCryptPasswordEncoder encoder = new BCryptPasswordEncoder();
String encodedPassword = encoder.encode(rawPassword);
admin.setPassword(encodedPassword);
// 不允许管理员通过编辑接口修改密码
admin.setPassword(null);
if (adminService.updateById(admin) == 0) {
return ResponseUtil.updatedDataFailed();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment