Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
gplanchat authored Jun 23, 2023
1 parent 35933a4 commit 7f79a66
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/WithSimpleOption.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ private function compile(string $code, string $attribute, string $labels, string
/**
* @return array<int, array<string, array<string, array|string>|string|null>>
*/
private function evaluate(array $context, string $code, string $attribute, array $labels, string|null $locale = null, string|null $scope = null): array
private function evaluate(array $context, string $code, string $attribute, array $labels, string $locale = 'null', string $scope = 'null'): array
{
return [[
'locale' => $locale,
Expand Down
2 changes: 1 addition & 1 deletion src/WithValue.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ private function compile(string $value, string $locale = 'null', string $scope =
return sprintf('([["data" => (%s), "locale" => (%s), "scope" => (%s)]])', $value, $locale, $scope);
}

private function evaluate(array $context, string $value, string|null $locale = null, string|null $scope = null): array
private function evaluate(array $context, string $value, string $locale = 'null', string $scope = 'null'): array
{
return [[
'locale' => $locale,
Expand Down

0 comments on commit 7f79a66

Please sign in to comment.