chia7712 commented on code in PR #22060:
URL: https://github.com/apache/kafka/pull/22060#discussion_r3325192159
##########
clients/src/main/java/org/apache/kafka/common/security/oauthbearer/internals/unsecured/OAuthBearerScopeUtils.java:
##########
@@ -66,7 +65,7 @@ public static List<String> parseScope(String
spaceDelimitedScope) throws OAuthBe
retval.add(individualScopeItem);
}
}
- return Collections.unmodifiableList(retval);
+ return List.copyOf(retval);
Review Comment:
This collection is already brand new, so we don't need to deep copy it
--
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]