mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-31 20:13:49 +00:00
apply more cs rules for php-cs
This commit is contained in:
@@ -15,8 +15,6 @@ use Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface;
|
||||
use Symfony\Component\HttpFoundation\RequestStack;
|
||||
use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
use function array_key_exists;
|
||||
|
||||
final class TranslatableStringHelper implements TranslatableStringHelperInterface
|
||||
{
|
||||
private readonly string $defaultLocale;
|
||||
@@ -36,12 +34,12 @@ final class TranslatableStringHelper implements TranslatableStringHelperInterfac
|
||||
|
||||
$language = null === $request ? $this->defaultLocale : $request->getLocale();
|
||||
|
||||
if (array_key_exists($language, $translatableStrings)) {
|
||||
if (\array_key_exists($language, $translatableStrings)) {
|
||||
return $translatableStrings[$language];
|
||||
}
|
||||
|
||||
foreach ($this->translator->getFallbackLocales() as $locale) {
|
||||
if (array_key_exists($locale, $translatableStrings)) {
|
||||
if (\array_key_exists($locale, $translatableStrings)) {
|
||||
return $translatableStrings[$locale];
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user