Skip to content

Commit

Permalink
Add Symfony 4.3 kernel.locale_aware tag (#347)
Browse files Browse the repository at this point in the history
Symfony 4.3 does not use the TranslatorListener anymore to set the locale. Instead, the LocaleAwareListener is used to collect locale aware services
  • Loading branch information
endroid authored and Gilles Gauthier committed Aug 1, 2019
1 parent 91d1844 commit b110bc1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions DependencyInjection/LexikTranslationExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ public function buildTranslatorDefinition(ContainerBuilder $container)

$translator->setArguments($arguments);
$translator->addMethodCall('setConfigCacheFactory', [new Reference('config_cache_factory')]);
$translator->addTag('kernel.locale_aware');

$container->setDefinition('lexik_translation.translator', $translator);
}
Expand Down

0 comments on commit b110bc1

Please sign in to comment.