beyondcode / laravel-self-diagnosis

Perform Self-Diagnosis Tests On Your Laravel Application

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow configuration to override locale

fabioi opened this issue · comments

commented

Hello, thank you for the great package, it is indeed very useful! :)

Wanted just to ask if it would be possibile to add the option in the config file to override the locale used by the package, since I am located in Italy and now to use the package I would need to translate all the strings to Italian, which I am not that interested. Since deployments scripts and code are usually written in english, I would actually prefer to have the messages in english.

Thank you in advance!

Fabio

I agree, I've got a similar issue. I'm using locale in the format en_GB, en_US etc. My fallback locale is formatted the same way.

After installing and running the artisan command, the translation keys are displayed instead of the translations.

I've fixed this for now by publishing the translations and renaming /resources/lang/vendor/self-diagnosis/en to /resources/lang/vendor/self-diagnosis/en_GB, but I rather not publish the translation files and just use the default ones due to future updates.

A default locale setting in the config would fix this or maybe automaticity fallback to English if the app locale isn't found for the self-diagnose translations.

I think this is an addition to #8