desruisseaux commented on code in PR #2347:
URL: https://github.com/apache/maven/pull/2347#discussion_r2094616566


##########
impl/maven-impl/src/main/java/org/apache/maven/impl/DefaultDependencyResolver.java:
##########
@@ -191,18 +210,14 @@ public DependencyResolverResult 
resolve(DependencyResolverRequest request)
                         .map(Artifact::toCoordinates)
                         .collect(Collectors.toList());
                 Predicate<PathType> filter = request.getPathTypeFilter();
+                DefaultDependencyResolverResult resolverResult = new 
DefaultDependencyResolverResult(
+                        null, moduleCache(), collectorResult.getExceptions(), 
collectorResult.getRoot(), nodes.size());
                 if (request.getRequestType() == 
DependencyResolverRequest.RequestType.FLATTEN) {
-                    DefaultDependencyResolverResult flattenResult = new 
DefaultDependencyResolverResult(

Review Comment:
   The change was for removing code duplication. The exact same code was inside 
the two branches of the `if … else` statement, with only different variable 
names.



-- 
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: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to