Skip to content

Commit

Permalink
Merge branch '6.3' into 6.4
Browse files Browse the repository at this point in the history
* 6.3:
  minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
  Fix bad merge
  List CS fix in .git-blame-ignore-revs
  Fix implicitly-required parameters
  List CS fix in .git-blame-ignore-revs
  Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
  • Loading branch information
nicolas-grekas committed Jan 23, 2024
2 parents dee0c6e + 953711c commit 43810bd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion TranslatableInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@
*/
interface TranslatableInterface
{
public function trans(TranslatorInterface $translator, string $locale = null): string;
public function trans(TranslatorInterface $translator, ?string $locale = null): string;
}
2 changes: 1 addition & 1 deletion TranslatorInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ interface TranslatorInterface
*
* @throws \InvalidArgumentException If the locale contains invalid characters
*/
public function trans(string $id, array $parameters = [], string $domain = null, string $locale = null): string;
public function trans(string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string;

/**
* Returns the default locale.
Expand Down
2 changes: 1 addition & 1 deletion TranslatorTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function getLocale(): string
return $this->locale ?: (class_exists(\Locale::class) ? \Locale::getDefault() : 'en');
}

public function trans(?string $id, array $parameters = [], string $domain = null, string $locale = null): string
public function trans(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string
{
if (null === $id || '' === $id) {
return '';
Expand Down

0 comments on commit 43810bd

Please sign in to comment.