You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2020/05/02 13:07:32 UTC

[GitHub] [maven] mthmulders commented on a change in pull request #341: [MNG-6863] Support --also-make flag in combination with --resume-from. - Refactoring

mthmulders commented on a change in pull request #341:
URL: https://github.com/apache/maven/pull/341#discussion_r418957009



##########
File path: maven-core/src/main/java/org/apache/maven/graph/DefaultGraphBuilder.java
##########
@@ -144,43 +148,27 @@
 
         if ( !request.getSelectedProjects().isEmpty() )
         {
-            result = new ArrayList<>( projects.size() );
+            File reactorDirectory = getReactorDirectory( request );
 
-            File reactorDirectory = null;
-            if ( request.getBaseDirectory() != null )
-            {
-                reactorDirectory = new File( request.getBaseDirectory() );
-            }
-
-            Collection<MavenProject> selectedProjects = new LinkedHashSet<>( projects.size() );
+            Collection<MavenProject> selectedProjects = new LinkedHashSet<>( request.getSelectedProjects().size() );

Review comment:
       Why change the initial size of the `selectedProjects`? It used to be `projects.size()`, now it's `request.getSelectedProjects().size()`.




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

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