提交 217a7da4 编写于 作者: 智布道's avatar 智布道 👁 提交者: Gitee

!14 修复后台管理中心当用户没有分配用户角色时,报500错误

Merge pull request !14 from 要懂得舍得/master
......@@ -78,9 +78,11 @@ public class ShiroRealm extends AuthorizingRealm {
// 赋予角色
List<Role> roleList = roleService.listRolesByUserId(userId);
for (Role role : roleList) {
info.addRole(role.getName());
}
if (null != roleList) {
for (Role role : roleList) {
info.addRole(role.getName());
}
}
// 赋予权限
List<Resources> resourcesList = null;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册