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/12/13 20:28:24 UTC

[GitHub] [maven] rfscholte commented on a change in pull request #391: Mng 6957: Support Build Consumer while defining modules in reverse order

rfscholte commented on a change in pull request #391:
URL: https://github.com/apache/maven/pull/391#discussion_r541998823



##########
File path: maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilder.java
##########
@@ -263,21 +264,14 @@ private DependencyResolutionResult resolveDependencies( MavenProject project, Re
 
     private List<String> getProfileIds( List<Profile> profiles )
     {
-        List<String> ids = new ArrayList<>( profiles.size() );
-
-        for ( Profile profile : profiles )
-        {
-            ids.add( profile.getId() );
-        }
-
-        return ids;
+        return profiles.stream().map( Profile::getId ).collect( Collectors.toList() );
     }
 
     private ModelBuildingRequest getModelBuildingRequest( InternalConfig config )
     {
         ProjectBuildingRequest configuration = config.request;
 
-        ModelBuildingRequest request = new DefaultModelBuildingRequest();
+        DefaultModelBuildingRequest request = new DefaultModelBuildingRequest();

Review comment:
       Not anymore, during refactoring there was a period where I needed it. Changed it back.




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