diff options
author | Tobias Stadler <ts.stadler@gmx.de> | 2020-07-25 22:02:39 +0200 |
---|---|---|
committer | sonartech <sonartech@sonarsource.com> | 2021-06-18 20:03:41 +0000 |
commit | 7b3853ad9c32b823ea3a70023e462b6b813e1a22 (patch) | |
tree | f872543b045ac5bec36d391651927e50e889de35 /sonar-plugin-api-impl/src/main | |
parent | e451875e4ba85ae989a5f1a84ca4f9e5de465431 (diff) | |
download | sonarqube-7b3853ad9c32b823ea3a70023e462b6b813e1a22.tar.gz sonarqube-7b3853ad9c32b823ea3a70023e462b6b813e1a22.zip |
SONAR-15056 It should be possible to create external issues with project location
Diffstat (limited to 'sonar-plugin-api-impl/src/main')
-rw-r--r-- | sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/sensor/issue/internal/DefaultExternalIssue.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/sensor/issue/internal/DefaultExternalIssue.java b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/sensor/issue/internal/DefaultExternalIssue.java index eca02788543..93c298d76ea 100644 --- a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/sensor/issue/internal/DefaultExternalIssue.java +++ b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/sensor/issue/internal/DefaultExternalIssue.java @@ -20,11 +20,11 @@ package org.sonar.api.batch.sensor.issue.internal; import javax.annotation.Nullable; +import org.sonar.api.batch.fs.internal.DefaultInputProject; import org.sonar.api.batch.rule.Severity; import org.sonar.api.batch.sensor.internal.SensorStorage; import org.sonar.api.batch.sensor.issue.ExternalIssue; import org.sonar.api.batch.sensor.issue.NewExternalIssue; -import org.sonar.api.batch.fs.internal.DefaultInputProject; import org.sonar.api.rule.RuleKey; import org.sonar.api.rules.RuleType; @@ -86,7 +86,6 @@ public class DefaultExternalIssue extends AbstractDefaultIssue<DefaultExternalIs requireNonNull(this.engineId, "Engine id is mandatory on external issue"); requireNonNull(this.ruleId, "Rule id is mandatory on external issue"); checkState(primaryLocation != null, "Primary location is mandatory on every external issue"); - checkState(primaryLocation.inputComponent().isFile(), "External issues must be located in files"); checkState(primaryLocation.message() != null, "External issues must have a message"); checkState(severity != null, "Severity is mandatory on every external issue"); checkState(type != null, "Type is mandatory on every external issue"); |