From 9e8e346e71b304fcf7aeb4e4f4c9a3c7107e1a53 Mon Sep 17 00:00:00 2001 From: Simon Brandhof Date: Wed, 6 Apr 2016 10:23:06 +0200 Subject: Fix quality flaws --- .../src/main/java/org/sonar/colorizer/KeywordsTokenizer.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sonar-colorizer/src') diff --git a/sonar-colorizer/src/main/java/org/sonar/colorizer/KeywordsTokenizer.java b/sonar-colorizer/src/main/java/org/sonar/colorizer/KeywordsTokenizer.java index 4c68b680f27..2f1192fabeb 100644 --- a/sonar-colorizer/src/main/java/org/sonar/colorizer/KeywordsTokenizer.java +++ b/sonar-colorizer/src/main/java/org/sonar/colorizer/KeywordsTokenizer.java @@ -19,13 +19,13 @@ */ package org.sonar.colorizer; -import org.sonar.channel.CodeReader; - import java.util.Collections; import java.util.HashSet; +import java.util.Locale; import java.util.Set; import java.util.regex.Matcher; import java.util.regex.Pattern; +import org.sonar.channel.CodeReader; /** * @deprecated since 4.5.2 replace by highlighting mechanism @@ -79,7 +79,7 @@ public class KeywordsTokenizer extends NotThreadSafeTokenizer { private boolean isKeyword(String word) { if (!caseInsensitive && keywords.contains(word)) { return true; - } else if (caseInsensitive && keywords.contains(word.toUpperCase())) { + } else if (caseInsensitive && keywords.contains(word.toUpperCase(Locale.ENGLISH))) { return true; } return false; -- cgit v1.2.3