2

I'm using FosUserBundle and the only way to translate its security messages (like "Invalid credentials.") is to enable translator in app/config/config.yml (If there is another way, please let me know).

However, my app will not be a multilingual app. Enabling the translator within the whole application leads to "missing translation" notifications on debug toolbar for my every form.

So I would like to find a way to enable the translator just for FosUserBundle. Is this possible?

Note: I've already overriden FosUserBundle on my /src/UserBundle.

Lashae
  • 1,372
  • 1
  • 20
  • 36
  • You sure that you are seeing these messages in the live app too? Means using app.php instead of app_dev.php - otherwise try setting the config value of twig.strict_variables to false – Alexander Kludt Sep 16 '15 at 14:05
  • Alexander, since notifications are shown on the *debug toolbar* and debug toolbar is only visible on dev environment, no I don't see them on production :-) – Lashae Sep 16 '15 at 14:08
  • Well, then I don't see a reason - other than performance - to disable it. Maybe you can elaborate your concerns a little more – Alexander Kludt Sep 16 '15 at 16:51
  • Dear Alexander, having those warnings on the debug toolbar confuses us whether translation is really missing or not (It can be really missing for UserBundle relateed parts). Therefore, we would like to disable translation (use IdentityTranslator) for AppBundle. – Lashae Oct 02 '15 at 11:53

0 Answers0