Skip to content
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

[Unconfirmed] Lang not translating issue #351

Open
darbyjack opened this issue Nov 5, 2021 · 1 comment
Open

[Unconfirmed] Lang not translating issue #351

darbyjack opened this issue Nov 5, 2021 · 1 comment
Labels
core Related to the ACF Core

Comments

@darbyjack
Copy link
Contributor

As per requested, I've opened an issue with a possible problem discussed in Discord.

Not really sure if it's a bug or how to approach this but I've seen this a couple times now. If you have a language that you are supporting and you add it to the supportive languages but ACF does not have lang files for it, it will default all the ACF Lang keys to English, even if you have them overridden in the config file for your language. Any thoughts on an approach to fix this?

@chickeneer
Copy link
Collaborator

I don't use the locale system. But just looking at the code, most everything looks correct.

Your report seems ambiguous on how you are creating the problem. Especially the part...

it will default all the ACF Lang keys to English
English is the default for Locales so that makes sense for non included languages. Are you implying that EVERY language gets sent as English, or just your new language?
Here is where the message is calculated (based on locale). If it doesn't find the message it sends the default English locale message which seems intentional.
https://github.com/aikar/locales/blob/master/src/main/java/co/aikar/locales/LocaleManager.java#L83

You can change the default Locale, but that doesn't sound like what you are wanting- as it is on the global scale.
https://github.com/aikar/commands/blob/master/core/src/main/java/co/aikar/commands/Locales.java#L100

even if you have them overridden in the config file for your language
I don't know how ACF would know to load a config file for languages when that language is not registered with ACF. I guess my specific question is how you are registering your language as supported and how it can be both supported and not have lang files and expect it to work...

So how do we move forward? I don't have any clue what you are doing to create the problem. I would want to know what API methods you are calling to create the issue and what behavior you expect along with what specific behavior you are experiencing instead.

@chickeneer chickeneer reopened this Nov 7, 2021
@chickeneer chickeneer added the core Related to the ACF Core label Jun 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Related to the ACF Core
Projects
None yet
Development

No branches or pull requests

2 participants