diff options
author | Julien HENRY <julien.henry@sonarsource.com> | 2016-03-24 10:33:29 +0100 |
---|---|---|
committer | Julien HENRY <julien.henry@sonarsource.com> | 2016-03-24 10:33:29 +0100 |
commit | 3ede1b35d04dcff7e7c9d1b6c9230bdeae3417c7 (patch) | |
tree | 1bfe4c61a3fadb96c80ba87e9ee3643f6c56ff5a /sonar-scanner-engine/src/main | |
parent | 0fd2f2204c44b6b5ec82741233940b8471df06d8 (diff) | |
download | sonarqube-3ede1b35d04dcff7e7c9d1b6c9230bdeae3417c7.tar.gz sonarqube-3ede1b35d04dcff7e7c9d1b6c9230bdeae3417c7.zip |
Fix some quality flaws
Diffstat (limited to 'sonar-scanner-engine/src/main')
-rw-r--r-- | sonar-scanner-engine/src/main/java/org/sonar/batch/issue/ModuleIssues.java | 2 | ||||
-rw-r--r-- | sonar-scanner-engine/src/main/java/org/sonar/batch/mediumtest/TaskResult.java | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/sonar-scanner-engine/src/main/java/org/sonar/batch/issue/ModuleIssues.java b/sonar-scanner-engine/src/main/java/org/sonar/batch/issue/ModuleIssues.java index d120e018acd..23fb5820954 100644 --- a/sonar-scanner-engine/src/main/java/org/sonar/batch/issue/ModuleIssues.java +++ b/sonar-scanner-engine/src/main/java/org/sonar/batch/issue/ModuleIssues.java @@ -123,7 +123,7 @@ public class ModuleIssues { } } - private ScannerReport.TextRange toProtobufTextRange(ScannerReport.TextRange.Builder textRangeBuilder, TextRange primaryTextRange) { + private static ScannerReport.TextRange toProtobufTextRange(ScannerReport.TextRange.Builder textRangeBuilder, TextRange primaryTextRange) { textRangeBuilder.clear(); textRangeBuilder.setStartLine(primaryTextRange.start().line()); textRangeBuilder.setStartOffset(primaryTextRange.start().lineOffset()); diff --git a/sonar-scanner-engine/src/main/java/org/sonar/batch/mediumtest/TaskResult.java b/sonar-scanner-engine/src/main/java/org/sonar/batch/mediumtest/TaskResult.java index 9edee3c7208..8d10ad0b202 100644 --- a/sonar-scanner-engine/src/main/java/org/sonar/batch/mediumtest/TaskResult.java +++ b/sonar-scanner-engine/src/main/java/org/sonar/batch/mediumtest/TaskResult.java @@ -87,9 +87,9 @@ public class TaskResult implements org.sonar.batch.mediumtest.ScanTaskObserver { private void storeReportComponents(int componentRef, String parentModuleKey, String branch) { Component component = getReportReader().readComponent(componentRef); if (isNotEmpty(component.getKey())) { - reportComponents.put(component.getKey() + (isNotEmpty(branch) ? ":" + branch : ""), component); + reportComponents.put(component.getKey() + (isNotEmpty(branch) ? (":" + branch) : ""), component); } else { - reportComponents.put(parentModuleKey + (isNotEmpty(branch) ? ":" + branch : "") + ":" + component.getPath(), component); + reportComponents.put(parentModuleKey + (isNotEmpty(branch) ? (":" + branch) : "") + ":" + component.getPath(), component); } for (int childId : component.getChildRefList()) { storeReportComponents(childId, isNotEmpty(component.getKey()) ? component.getKey() : parentModuleKey, branch); |