Skip to content

Commit

Permalink
Add subgroup count to groupByPath (keycloak#33161)
Browse files Browse the repository at this point in the history
Closes keycloak#31410

Signed-off-by: Keshav Deshpande <[email protected]>
  • Loading branch information
keshavprashantdeshpande authored Sep 23, 2024
1 parent ba58110 commit 402aa42
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@
import org.keycloak.storage.DatastoreProvider;
import org.keycloak.storage.ExportImportManager;
import org.keycloak.storage.StoreSyncEvent;
import org.keycloak.utils.GroupUtils;
import org.keycloak.utils.ProfileHelper;
import org.keycloak.utils.ReservedCharValidator;

Expand Down Expand Up @@ -1093,7 +1094,8 @@ public GroupRepresentation getGroupByPath(@PathParam("path") String path) {

}
auth.groups().requireView(found);
return ModelToRepresentation.toRepresentation(found, true);
GroupRepresentation groupRep = ModelToRepresentation.toRepresentation(found, true);
return GroupUtils.populateSubGroupCount(found, groupRep);
}

/**
Expand Down

0 comments on commit 402aa42

Please sign in to comment.