From 131d8c9c272c3fce5bd706a5f0e5effc602f3550 Mon Sep 17 00:00:00 2001 From: Michael Zinsmaier Date: Thu, 8 Oct 2015 21:30:04 +0200 Subject: [PATCH] fixed parameter list for plugin creation --- .../ncredinburgh/sonar/scalastyle/ScalastyleRunner.scala | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/scala/com/ncredinburgh/sonar/scalastyle/ScalastyleRunner.scala b/src/main/scala/com/ncredinburgh/sonar/scalastyle/ScalastyleRunner.scala index 32ec0e3..30470f7 100755 --- a/src/main/scala/com/ncredinburgh/sonar/scalastyle/ScalastyleRunner.scala +++ b/src/main/scala/com/ncredinburgh/sonar/scalastyle/ScalastyleRunner.scala @@ -62,7 +62,11 @@ class ScalastyleRunner(rp: RulesProfile) { } private def ruleToChecker(activeRule: ActiveRule): ConfigurationChecker = { - val params = activeRule.getActiveRuleParams.map(p => (p.getKey, p.getValue)).toMap - ConfigurationChecker(params("scalastyle-checker"), ErrorLevel, true, params, None, None) + val sonarParams = activeRule.getActiveRuleParams.map(p => (p.getKey, p.getValue)).toMap + + val checkerParams = sonarParams.remove("scalastyle-checker") + val className = sonarParams("scalastyle-checker") + + ConfigurationChecker(className, ErrorLevel, true, sonarParams, None, None) } }