From 1331eec2084d349b45ca4968603948131576af74 Mon Sep 17 00:00:00 2001 From: Gwilym Kuiper Date: Fri, 3 Apr 2020 15:17:01 +0100 Subject: [PATCH] Make comment clearer --- .../codestyle/FieldDeclarationsShouldBeAtStartRule.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/codestyle/FieldDeclarationsShouldBeAtStartRule.java b/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/codestyle/FieldDeclarationsShouldBeAtStartRule.java index 58f3bbb217..6dc4c45b05 100644 --- a/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/codestyle/FieldDeclarationsShouldBeAtStartRule.java +++ b/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/codestyle/FieldDeclarationsShouldBeAtStartRule.java @@ -58,9 +58,9 @@ public class FieldDeclarationsShouldBeAtStartRule extends AbstractApexRule { } private List> getMethodNodes(ASTUserClass node) { - // The method represents static initializer blocks, of which there can be many. Given that the - // method doesn't contain location information, only the containing ASTBlockStatements, we fetch - // them for that method only. + // The method represents static initializer blocks, of which there can be many. The + // method doesn't contain location information, however the containing ASTBlockStatements do, + // so we fetch them for that method only. return node.findChildrenOfType(ASTMethod.class).stream() .flatMap(method -> method.getImage().equals("") ? method.findChildrenOfType(ASTBlockStatement.class).stream() : Stream.of(method))