We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c3c1c41 + 72bbe2b commit 86faecdCopy full SHA for 86faecd
1 file changed
src/Phpstan/EntityDataObjectPropertyHasNoTypehintRule.php
@@ -72,6 +72,10 @@ private function isDataObjectWithAssociatedEntity(Scope $scope): bool
72
$reflectionClass = new ReflectionClass(substr($className, 0, -4));
73
$docComment = $reflectionClass->getDocComment();
74
75
+ if ($docComment === false) {
76
+ return false;
77
+ }
78
+
79
return str_contains($docComment, '@ORM\Entity');
80
} catch (ReflectionException) {
81
return false;
0 commit comments