smjn commented on code in PR #19328:
URL: https://github.com/apache/kafka/pull/19328#discussion_r2024640257
##########
clients/src/main/java/org/apache/kafka/clients/admin/ListShareGroupOffsetsSpec.java:
##########
@@ -47,9 +46,10 @@ public ListShareGroupOffsetsSpec
topicPartitions(Collection<TopicPartition> topi
/**
* Returns the topic partitions whose offsets are to be listed for a share
group.
+ * {@code null} indicates that offsets of all partitions of the group are
to be listed.
*/
public Collection<TopicPartition> topicPartitions() {
- return topicPartitions == null ? List.of() : topicPartitions;
+ return topicPartitions;
Review Comment:
would it be neater to use Optional.ofNullable?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]