Skip to content

Commit 203b934

Browse files
committed
fix
1 parent 8e6463b commit 203b934

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

rules/CodingStyle/Rector/ClassMethod/BinaryOpStandaloneAssignsToDirectRector.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
use PhpParser\Node;
88
use PhpParser\Node\Expr\Assign;
99
use PhpParser\Node\Expr\BinaryOp;
10+
use PhpParser\Node\Expr\CallLike;
1011
use PhpParser\Node\Expr\Closure;
1112
use PhpParser\Node\Expr\MethodCall;
1213
use PhpParser\Node\Expr\Variable;
@@ -133,7 +134,7 @@ private function matchToVariableAssignExpr(Stmt $stmt): ?VariableAndExprAssign
133134
}
134135

135136
// skip complex cases
136-
if ($assign->expr instanceof MethodCall && $assign->expr->args !== []) {
137+
if ($assign->expr instanceof CallLike && $assign->expr->args !== []) {
137138
return null;
138139
}
139140

0 commit comments

Comments
 (0)