]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-21268 Fixed issues can be null in PR decoration
authorEric Giffon <eric.giffon@sonarsource.com>
Wed, 31 Jan 2024 14:10:12 +0000 (15:10 +0100)
committersonartech <sonartech@sonarsource.com>
Thu, 1 Feb 2024 20:02:47 +0000 (20:02 +0000)
sonar-ws/src/main/java/org/sonarqube/ws/client/projects/CreateRequest.java
sonar-ws/src/main/java/org/sonarqube/ws/client/projects/ProjectsService.java

index a89760b4be58ace8beb83fd299b3abd3717f0494..c24bdcf58e35509b6c1e8af6803055ef86fdd5a1 100644 (file)
@@ -30,21 +30,21 @@ import javax.annotation.Generated;
 @Generated("sonar-ws-generator")
 public class CreateRequest {
 
-  private String branch;
+  private String mainBranch;
   private String name;
   private String project;
   private String visibility;
 
   /**
-   * Example value: "branch-5.0"
+   * Example value: "master"
    */
-  public CreateRequest setBranch(String branch) {
-    this.branch = branch;
+  public CreateRequest setMainBranch(String mainBranch) {
+    this.mainBranch = mainBranch;
     return this;
   }
 
-  public String getBranch() {
-    return branch;
+  public String getMainBranch() {
+    return mainBranch;
   }
 
   /**
index 98c82c0a2c2d4f5cc77677e5cf25bf98bdf97456..c63409ad03afe535cbaa64c060b61874de1cc4c4 100644 (file)
@@ -71,7 +71,7 @@ public class ProjectsService extends BaseService {
   public CreateWsResponse create(CreateRequest request) {
     return call(
       new PostRequest(path("create"))
-        .setParam("branch", request.getBranch())
+        .setParam("mainBranch", request.getMainBranch())
         .setParam("name", request.getName())
         .setParam("project", request.getProject())
         .setParam("visibility", request.getVisibility()),