LocaleBundle
LocaleBundle copied to clipboard
Symfony 4 compatibility: Service visibility deprecation
User Deprecated: The "lunetics_locale.allowed_locales_provider" service is private,
getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0.
You should either make the service public, or stop using the container directly
and use dependency injection instead.
User Deprecated: The "lunetics_locale.switcher_helper" service is private,
getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0.
You should either make the service public, or stop using the container directly
and use dependency injection instead.
Just updated to 3.4 and noticed these deprecations amongst others of ours. I find it a bit weird that the tests are passing for symfony 4 for this bundle but haven't tried the combination yet myself. Am I missing something? The related code/configuration seems unchanged.
maybe the tests are lacking. are you sure you do not access this services with a $container->get() yourself? if its in this bundle, we should fix it to DI instead.
ups. can you try to rewrite that to inject the services and parameters in the constructor, instead of pulling them from the container?