]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-4069 Fix issue with configuration when using old API (without task)
authorJulien HENRY <julien.henry@sonarsource.com>
Mon, 21 Jan 2013 09:29:55 +0000 (10:29 +0100)
committerJulien HENRY <julien.henry@sonarsource.com>
Mon, 21 Jan 2013 09:30:55 +0000 (10:30 +0100)
sonar-batch/src/main/java/org/sonar/batch/bootstrapper/Batch.java

index 1918abaf85ed24faca0e2fd86a319a1dd21c7d33..cbab3ddb416f48a82eca1809260401405dac3809 100644 (file)
@@ -52,6 +52,10 @@ public final class Batch {
     if (builder.globalProperties != null) {
       globalProperties.putAll(builder.globalProperties);
     }
+    else {
+      // For backward compatibility, previously all properties were set in root project
+      globalProperties.putAll(Maps.fromProperties(builder.projectReactor.getRoot().getProperties()));
+    }
     this.taskCommand = builder.taskCommand;
     projectReactor = builder.projectReactor;
     if (builder.isEnableLoggingConfiguration()) {