forked from phoedos/pmd
Fix b/243747010
Set `ASTMethod.getImage` to name of type for constructors
This commit is contained in:
parent
90aec7a9e1
commit
9e5d4d48a8
@ -50,6 +50,12 @@ public class ASTMethod extends AbstractApexNode.Single<MethodDeclaration> implem
|
||||
|
||||
@Override
|
||||
public String getImage() {
|
||||
if (node.isConstructor()) {
|
||||
ApexRootNode<?> rootNode = getFirstParentOfType(ApexRootNode.class);
|
||||
if (rootNode != null) {
|
||||
return rootNode.node.getId().getString();
|
||||
}
|
||||
}
|
||||
return getName();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user