add static call check

This commit is contained in:
TomasVotruba 2020-06-18 01:12:19 +02:00
parent 5371a84cb1
commit 03cf74ce31

View File

@ -8,6 +8,7 @@ use PhpParser\Node;
use PhpParser\Node\Expr\Assign;
use PhpParser\Node\Expr\Closure;
use PhpParser\Node\Expr\MethodCall;
use PhpParser\Node\Expr\StaticCall;
use PhpParser\Node\Stmt\ClassMethod;
use PhpParser\Node\Stmt\Expression;
use PhpParser\Node\Stmt\Function_;
@ -92,7 +93,7 @@ PHP
continue;
}
if (! $stmt->var instanceof MethodCall) {
if (! $stmt->var instanceof MethodCall && ! $stmt->var instanceof StaticCall) {
$currentStmtVariableName = $this->getName($stmt->var);
}
}