WPB-19257: Add member count to user group list#4714
Merged
blackheaven merged 9 commits intodevelopfrom Aug 28, 2025
Merged
Conversation
dfbb0c6 to
4beb4b0
Compare
b54059c to
2b7241d
Compare
eee492b to
6dce400
Compare
battermann
approved these changes
Aug 27, 2025
Contributor
battermann
left a comment
There was a problem hiding this comment.
I approve already, but please consider addressing my comment
Comment on lines
910
to
915
| instance (ToSchema a) => ToSchema (Identity a) where schema = dimap runIdentity Identity schema | ||
|
|
||
| instance (ToSchema a) => ToSchema (Const a x) where schema = dimap getConst Const schema | ||
|
|
||
| instance (S.ToSchema a, A.ToJSON a, A.FromJSON a) => ToSchema (Maybe a) where schema = genericToSchema | ||
|
|
Contributor
There was a problem hiding this comment.
I am not sure how that behaves.
If we want to be consistent with the rest of our code base, we can just define the part in the ToSchema instance as follows:
<*> (.membersCount) .= maybe_ (optField "membersCount" schema)
Contributor
Author
There was a problem hiding this comment.
It's not needed anymore, dropping it
battermann
reviewed
Aug 27, 2025
| <$> (.id_) .= field "id" schema | ||
| <*> (.name) .= field "name" schema | ||
| <*> (.members) .= pure mempty | ||
| <*> (.membersCount) .= field "membersCount" schema |
Contributor
There was a problem hiding this comment.
shouldn't this be maybe_ (optField ...
Contributor
There was a problem hiding this comment.
I think this would be good so that the field is omitted when the flag is not provided
Contributor
Author
There was a problem hiding this comment.
You're right, thanks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://wearezeta.atlassian.net/browse/WPB-19257
Checklist
changelog.d