diff --git a/src/Closures/NoParameterWithNullableTypeDeclarationRule.php b/src/Closures/NoParameterWithNullableTypeDeclarationRule.php index 3e7e0edb..13ea6804 100644 --- a/src/Closures/NoParameterWithNullableTypeDeclarationRule.php +++ b/src/Closures/NoParameterWithNullableTypeDeclarationRule.php @@ -36,11 +36,11 @@ public function processNode( return []; } - $params = \array_filter($node->params, static function (Node\Param $node): bool { + $parametersWithNullableTypeDeclaration = \array_filter($node->params, static function (Node\Param $node): bool { return self::isNullable($node); }); - if (0 === \count($params)) { + if (0 === \count($parametersWithNullableTypeDeclaration)) { return []; } @@ -59,7 +59,7 @@ public function processNode( return Rules\RuleErrorBuilder::message($message) ->identifier(ErrorIdentifier::noParameterWithNullableTypeDeclaration()->toString()) ->build(); - }, $params)); + }, $parametersWithNullableTypeDeclaration)); } private static function isNullable(Node\Param $node): bool