diff options
author | simonbrandhof <simon.brandhof@gmail.com> | 2011-01-10 00:40:45 +0100 |
---|---|---|
committer | simonbrandhof <simon.brandhof@gmail.com> | 2011-01-10 00:40:45 +0100 |
commit | 9f0a786894a83c6cc47efc1b107b7c1232b3bc36 (patch) | |
tree | e4b7848d2c29a96291051646e81cdddb1958c41f | |
parent | 287126153cceb8deec795faeff3525cdabab3ced (diff) | |
download | sonarqube-9f0a786894a83c6cc47efc1b107b7c1232b3bc36.tar.gz sonarqube-9f0a786894a83c6cc47efc1b107b7c1232b3bc36.zip |
Rule.getRulesCategory() must return a fake category instead of null
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java b/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java index 6a33cb6c5f6..238763e2603 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java @@ -35,6 +35,8 @@ import javax.persistence.*; @Table(name = "rules")
public final class Rule {
+ private final static RulesCategory NONE = new RulesCategory("none");
+
@Id
@Column(name = "id")
@GeneratedValue
@@ -190,7 +192,7 @@ public final class Rule { */
@Deprecated
public RulesCategory getRulesCategory() {
- return null;
+ return NONE;
}
/**
|