add fine grain access to subgroups (#16672)

fixes: https://github.com/keycloak/keycloak-ui/issues/4195
This commit is contained in:
Erik Jan de Wit 2023-01-27 20:20:26 +01:00 committed by GitHub
parent c4255e7301
commit 5f8ee1c49d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -76,10 +76,13 @@ public class GroupsResource {
groupMatchesSearchOrIsPathElement(
g, search
)
).map(subGroup ->
ModelToRepresentation.toGroupHierarchy(
subGroup, true, search, exact
)
).map(subGroup -> {
final GroupRepresentation subRep = ModelToRepresentation.toGroupHierarchy(
subGroup, true, search, exact
);
subRep.setAccess(auth.groups().getAccess(subGroup));
return subRep;
}
).collect(Collectors.toList()));
return rep;