-
Notifications
You must be signed in to change notification settings - Fork 11.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[6.x] Fix for empty fallback_locale #34136
Conversation
I tried to update laravel version but I think this fix is not released yet. |
@ahmedsayedabdelsalam releases are done on Tuesdays. |
Great! Thanks. |
We've reverted this as this was a breaking change. |
Is there any plan to fix that or this is not an issue? |
This was the expected behavior and it's unlikely that we'll ever change this. |
Hmmm. Most of Excel Sheet Translation packages pull the not translated languages as an empty string value and I think it's logic because the data type for translations is designed to be strings For me I'll fix it in my project but I suggest making a config key determines when the translator should fallback if an empty strings or null. Like: 'fallback_when_empty' => true, // translations.php config file Anyway thanks for your time. |
// ar
'foo' => ''
// en
'foo', => 'bar'
before
trans('file.foo',[],'ar') // ''
after
trans('file.foo',[],'ar') // 'bar'
#34128