From 22c434e62341d36b550db0f9128c902972d3ba2f Mon Sep 17 00:00:00 2001 From: Stephane Gamard Date: Tue, 1 Jul 2014 16:50:20 +0200 Subject: [PATCH] fix quality flaws --- .../src/main/java/org/sonar/server/rule/index/RuleIndex.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sonar-server/src/main/java/org/sonar/server/rule/index/RuleIndex.java b/sonar-server/src/main/java/org/sonar/server/rule/index/RuleIndex.java index 7b482f6d541..15f2926ee21 100644 --- a/sonar-server/src/main/java/org/sonar/server/rule/index/RuleIndex.java +++ b/sonar-server/src/main/java/org/sonar/server/rule/index/RuleIndex.java @@ -298,10 +298,10 @@ public class RuleIndex extends BaseIndex { } /** Implementation of activation query */ - if (query.getActivation().equals(Boolean.TRUE)) { + if (Boolean.TRUE.equals(query.getActivation())) { fb.must(FilterBuilders.hasChildFilter(IndexDefinition.ACTIVE_RULE.getIndexType(), childQuery)); - } else if (query.getActivation().equals(Boolean.FALSE)) { + } else if (Boolean.FALSE.equals(query.getActivation())) { fb.mustNot(FilterBuilders.hasChildFilter(IndexDefinition.ACTIVE_RULE.getIndexType(), childQuery)); } -- 2.39.5