Skip to content

Commit

Permalink
fix visibility
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim MacDonald authored and timacdonald committed Nov 30, 2021
1 parent 5d835b4 commit f1845ed
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ class ThrottleRequests
//
}

protected static function parameterAliasMap(): array
private static function parameterAliasMap(): array
{
return [
'limiter' => 'maxAttempts',
Expand All @@ -195,7 +195,7 @@ Ensures all required parameters (those without default values) have been provide

- Ensures all aliases specified reference an existing parameter.
- Provided aliases don't reference the same parameter.
- An original parameter key and an alias have not both be provided.
- An original parameter key and an alias have not both been provided.

## Middleware::in()

Expand Down
4 changes: 1 addition & 3 deletions src/HasParameters.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,9 @@ public static function in($arguments): string
}

/**
* @psalm-suppress ProtectedVisibility
*
* @return array<string, string>
*/
protected static function parameterAliasMap(): array
private static function parameterAliasMap(): array
{
return [
// 'alias' => 'parameter',
Expand Down
4 changes: 2 additions & 2 deletions tests/HasParametersTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ public function handle(Request $request, Closure $next, string $original, string
//
}

protected static function parameterAliasMap(): array
private static function parameterAliasMap(): array
{
return [
'firstAlias' => 'original',
Expand Down Expand Up @@ -337,7 +337,7 @@ public function handle(Request $request, Closure $next, string $original): void
//
}

protected static function parameterAliasMap(): array
private static function parameterAliasMap(): array
{
return [
'firstAlias' => 'doesntExist',
Expand Down
2 changes: 1 addition & 1 deletion tests/Middleware/Aliased.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public function handle(Request $request, Closure $next, string $originalFirst, s
//
}

protected static function parameterAliasMap(): array
private static function parameterAliasMap(): array
{
return [
'aliasedFirst' => 'originalFirst',
Expand Down

0 comments on commit f1845ed

Please sign in to comment.