Skip to content

Commit

Permalink
Merge pull request #21 from godfather1103/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
godfather1103 authored Nov 17, 2023
2 parents 9eeac32 + ce8bbd5 commit 13e4bde
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion idea-plugin/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ systemProp.file.encoding=UTF-8
# \u63D2\u4EF6\u7248\u672C
plugin_version=1.4
# \u4F7F\u7528\u7684p3c-pmd\u7248\u672C
p3c_pmd_version=2.1.1-ext-2
p3c_pmd_version=2.1.1-ext-3
publishUsername=Jack Chu
publishToken=
publishChannel=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,15 @@
public class LowerCamelCaseVariableNamingRule extends AbstractAliRule {

private static final String MESSAGE_KEY_PREFIX = "java.naming.LowerCamelCaseVariableNamingRule.violation.msg";
private static Pattern pattern;
private static Pattern pattern = null;

static {
makePattern(
NameListConfig.NAME_LIST_SERVICE
.getNameList("LowerCamelCaseVariableNamingRule", "WHITE_LIST")
);
public LowerCamelCaseVariableNamingRule() {
if (pattern == null) {
makePattern(
NameListConfig.NAME_LIST_SERVICE
.getNameList("LowerCamelCaseVariableNamingRule", "WHITE_LIST")
);
}
}

public static void makePattern(List<String> list) {
Expand Down

0 comments on commit 13e4bde

Please sign in to comment.