Skip to content

Commit

Permalink
feat: add POST /rolePermissionsMapping for adding new rolePermissions…
Browse files Browse the repository at this point in the history
…Mapping entry #144
  • Loading branch information
duttarnab committed Jan 7, 2022
1 parent 31eaa1e commit 26a4efb
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -303,10 +303,9 @@ public List<RolePermissionMapping> removePermissionsFromRole(RolePermissionMappi
private List<RolePermissionMapping> getRolePermMapByRole(AdminConf adminConf, RolePermissionMapping rolePermissionMappingArg) throws ApplicationException {
validateRolePermissionMapping(adminConf, rolePermissionMappingArg);

List<RolePermissionMapping> roleScopeMappingList = adminConf.getDynamic().getRolePermissionMapping()
return adminConf.getDynamic().getRolePermissionMapping()
.stream().filter(ele -> ele.getRole().equalsIgnoreCase(rolePermissionMappingArg.getRole()))
.collect(Collectors.toList());
return roleScopeMappingList;
}

private void validateRolePermissionMapping(AdminConf adminConf, RolePermissionMapping rolePermissionMappingArg) throws ApplicationException {
Expand Down

0 comments on commit 26a4efb

Please sign in to comment.