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 2022/12/13 15:52:38 UTC

[GitHub] [maven] gnodet commented on a diff in pull request #909: [MNG-7625] Restore compatibility with Maven 3 - SettingsUtils#merge

gnodet commented on code in PR #909:
URL: https://github.com/apache/maven/pull/909#discussion_r1047350107


##########
maven-core/src/main/java/org/apache/maven/settings/SettingsUtils.java:
##########
@@ -51,6 +52,25 @@ public static Settings merge(Settings dominant, Settings recessive, String reces
         return new MavenSettingsMerger().merge(dominant, recessive, recessiveSourceLevel);
     }
 
+    /**
+     * @param dominant
+     * @param recessive
+     * @param recessiveSourceLevel
+     * @deprecated please use {@link #merge(Settings, Settings, String)}
+     */
+    @Deprecated
+    public static void merge(
+            org.apache.maven.settings.Settings dominant,
+            org.apache.maven.settings.Settings recessive,
+            String recessiveSourceLevel) {
+
+        if (dominant == null || recessive == null) {
+            return;
+        }
+
+        dominant.delegate = new SettingsMerger().merge(dominant.getDelegate(), recessive.getDelegate(), true, null);

Review Comment:
   I think it should be the same than the method above:
   ```new MavenSettingsMerger().merge(dominant.getDelegate(), recessive.getDelegate(), recessiveSourceLevel)``` instead.



-- 
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-unsubscribe@maven.apache.org

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