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 Dec 17, 2024
1 parent 986142e commit 675e8ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rules/Php81/Rector/ClassMethod/NewInInitializerRector.php
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ private function matchConstructorParams(ClassMethod $classMethod): array

$totalParams = count($classMethod->params);

foreach ($params as $key => $param) {
foreach (array_keys($params) as $key) {
for ($iteration = $key + 1; $iteration < $totalParams; ++$iteration) {
if (isset($classMethod->params[$iteration]) && ! $classMethod->params[$iteration]->default instanceof Expr) {
return [];
Expand Down

0 comments on commit 675e8ef

Please sign in to comment.