Skip to content

Commit

Permalink
[ci-review] Rector Rectify
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Apr 24, 2023
1 parent 373efd0 commit 5bff1fe
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Application/FileProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public function refactor(File $file, Configuration $configuration): void
$file->changeNewStmts($newStmts);

$this->affectedFilesCollector->removeFromList($file);
while ($otherTouchedFile = $this->affectedFilesCollector->getNext()) {
while (($otherTouchedFile = $this->affectedFilesCollector->getNext()) instanceof File) {
$this->refactor($otherTouchedFile, $configuration);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/PhpParser/Node/BetterNodeFinder.php
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,7 @@ public function resolveCurrentStatement(Node $node): ?Stmt
}

$currentStmt = $node;
while ($currentStmt = $currentStmt->getAttribute(AttributeKey::PARENT_NODE)) {
while (($currentStmt = $currentStmt->getAttribute(AttributeKey::PARENT_NODE)) instanceof Node) {
if ($currentStmt instanceof Stmt) {
return $currentStmt;
}
Expand Down

0 comments on commit 5bff1fe

Please sign in to comment.