Skip to content

Commit 67db884

Browse files
committed
[ci-review] Rector Rectify
1 parent 607e6cd commit 67db884

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

rules/DeadCode/Rector/ClassMethod/RemoveParentDelegatingConstructorRector.php

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

55
namespace Rector\DeadCode\Rector\ClassMethod;
66

7+
use PhpParser\Node\Expr\Variable;
78
use PhpParser\Node;
89
use PhpParser\Node\Arg;
910
use PhpParser\Node\Expr\StaticCall;
@@ -102,14 +103,14 @@ public function refactor(Node $node): ?int
102103

103104
// match passed names in the same order
104105
$paramNames = [];
105-
foreach ($constructorParams as $param) {
106-
$paramNames[] = $this->getName($param->var);
106+
foreach ($constructorParams as $constructorParam) {
107+
$paramNames[] = $this->getName($constructorParam->var);
107108
}
108109

109110
$argNames = [];
110111
foreach ($parentCallArgs as $parentCallArg) {
111112
$argValue = $parentCallArg->value;
112-
if (! $argValue instanceof Node\Expr\Variable) {
113+
if (! $argValue instanceof Variable) {
113114
return null;
114115
}
115116

src/Comments/NodeTraverser/CommentRemovingNodeTraverser.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,7 @@
55
namespace Rector\Comments\NodeTraverser;
66

77
use PhpParser\NodeTraverser;
8-
use Rector\Comments\NodeVisitor\CommentRemovingNodeVisitor;
98

109
final class CommentRemovingNodeTraverser extends NodeTraverser
1110
{
12-
public function __construct(CommentRemovingNodeVisitor $commentRemovingNodeVisitor)
13-
{
14-
parent::__construct($commentRemovingNodeVisitor);
15-
}
1611
}

0 commit comments

Comments
 (0)