Skip to content

Commit

Permalink
(ci) fix phpstan
Browse files Browse the repository at this point in the history
  • Loading branch information
kevincobain2000 committed May 23, 2024
1 parent 1ce62f5 commit 994cdec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/LaravelRequestDocs.php
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ public function rulesByRegex(string $requestClassName, string $methodName): arra
->filter(function ($item) {
return count($item[0]) > 0;
})
->transform(function ($item) {
->transform(function (array $item, int $key) {

Check failure on line 385 in src/LaravelRequestDocs.php

View workflow job for this annotation

GitHub Actions / PHP lint

Parameter #1 $callback of method Illuminate\Support\Collection<int,array<array<int, string>>>::transform() expects callable(array<array<int, string>>, int): array<array<int, string>>, Closure(array, int): array{key: Illuminate\Support\Stringable, rules: array} given.
$fieldName = Str::of($item[0][0])->replace(['"', "'"], '');
$definedFieldRules = collect(array_slice($item[0], 1))->transform(function ($rule) {
return Str::of($rule)->replace(['"', "'"], '')->__toString();
Expand Down

0 comments on commit 994cdec

Please sign in to comment.