Skip to content

Commit ab48181

Browse files
committed
[ci-review] Rector Rectify
1 parent bba767d commit ab48181

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

rules/Php70/NodeAnalyzer/MethodCallNameAnalyzer.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55
namespace Rector\Php70\NodeAnalyzer;
66

7+
use PhpParser\Node\Expr\Variable;
8+
use PhpParser\Node\Stmt\ClassMethod;
79
use PhpParser\Node\Expr;
810
use PhpParser\Node\Expr\MethodCall;
911
use PhpParser\Node\Identifier;
@@ -18,7 +20,7 @@ public function isLocalMethodCallNamed(Expr $expr, string $desiredMethodName): b
1820
return false;
1921
}
2022

21-
if (! $expr->var instanceof Expr\Variable) {
23+
if (! $expr->var instanceof Variable) {
2224
return false;
2325
}
2426

@@ -40,7 +42,7 @@ public function isParentMethodCall(Class_ $class, Expr $expr): bool
4042
}
4143

4244
$parentClassName = $class->extends->toString();
43-
if ($class->getMethod($parentClassName)) {
45+
if ($class->getMethod($parentClassName) instanceof ClassMethod) {
4446
return false;
4547
}
4648

0 commit comments

Comments
 (0)