Skip to content

Commit 8ac44bc

Browse files
committed
Fix
1 parent 0119a35 commit 8ac44bc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

rules/CodeQuality/Rector/Class_/AddParamTypeFromDependsRector.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,10 @@ private function resolveReturnTypeOfDependsMethod(ClassMethod $classMethod, Clas
135135
{
136136
$dependsMethodName = $this->resolveDependsAnnotationOrAttributeMethod($classMethod);
137137

138+
if ($dependsMethodName === null || $dependsMethodName === '') {
139+
return null;
140+
}
141+
138142
$dependsClassMethod = $class->getMethod($dependsMethodName);
139143

140144
if (! $dependsClassMethod instanceof ClassMethod) {

0 commit comments

Comments
 (0)