goutamadwant commented on code in PR #13041:
URL: https://github.com/apache/maven/pull/13041#discussion_r3946791634


##########
impl/maven-core/src/main/java/org/apache/maven/model/plugin/DefaultLifecycleBindingsInjector.java:
##########
@@ -75,17 +77,31 @@ public void injectLifecycleBindings(Model model, 
ModelBuildingRequest request, M
             lifecycleModel.setBuild(new Build());
             lifecycleModel.getBuild().getPlugins().addAll(defaultPlugins);
 
-            merger.merge(model, lifecycleModel);
+            new LifecycleBindingsMerger(getPhaseToLifecycleMap()).merge(model, 
lifecycleModel);

Review Comment:
   I kept the lookup dynamic because extensions can register lifecycle phases 
after injector construction. Added a comment and tests in both model 
implementations that register another phase between injections.



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