gnodet-bot commented on code in PR #395:
URL: https://github.com/apache/maven-filtering/pull/395#discussion_r4094383597


##########
src/main/java/org/apache/maven/shared/filtering/Resource.java:
##########
@@ -53,6 +54,41 @@ public void setExcludes(List<String> excludes) {
         this.excludes = excludes;
     }
 
+    /**
+     * Returns the list of Ant-style glob patterns that should be copied as-is 
(without filtering),
+     * even when this resource has {@code <filtering>true</filtering>}. 
Patterns are matched
+     * against the relative file path within the resource directory.
+     *
+     * @return the list of non-filtered file glob patterns, or {@code null} if 
none are configured
+     * @since 3.4.0
+     */
+    public List<String> getNonFilteredFiles() {
+        return nonFilteredFiles;

Review Comment:
   ⚠️ **Mutable collection returned directly**
   
    hands out the internal  — callers can mutate it behind 's back (e.g. ). 
Since this is a new public API, seal it at introduction.
   
   
   
    is already available without new imports (it's ). The  mutation path goes 
through the setter/adder methods, so internal mutation still works.



-- 
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]

Reply via email to