Created
April 19, 2019 08:06
-
-
Save DaGhostman/a9c430adaf76001259658a65199c5707 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/Visitor/CodeCoverageMethodIgnoreVisitor.php b/src/Visitor/CodeCoverageMethodIgnoreVisitor.php | |
index f1bd6fd..305770d 100644 | |
--- a/src/Visitor/CodeCoverageMethodIgnoreVisitor.php | |
+++ b/src/Visitor/CodeCoverageMethodIgnoreVisitor.php | |
@@ -53,6 +53,10 @@ final class CodeCoverageMethodIgnoreVisitor extends NodeVisitorAbstract | |
/** @var \ReflectionClass $reflection */ | |
$reflection = $node->getAttribute(ReflectionVisitor::REFLECTION_CLASS_KEY); | |
+ if (!$reflection->hasMethod($node->name->toString())) { | |
+ return null; | |
+ } | |
+ | |
$method = $reflection->getMethod($node->name->toString()); | |
$docComment = $method->getDocComment(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment