-
Notifications
You must be signed in to change notification settings - Fork 57
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
ApiController: Unable to load the requested language file #143
Comments
@lonnieezell thanks but this fix set a default language if the browser doesn't suggest any, the problem remain if the browser does suggest one (or more) because CI's
I don't see any way in BTW: Happy new year! |
Oh, dang, you're right. I read your initial post incorrectly. I will need to add a check to see if that folder and file exists within the APIController to avoid that, or extend the Lang library. I won't have anytime today, but should be able to look at that tomorrow night or Monday. |
Got a chance to look at this today. For now, a fix is in place with one caveat that I don't think is too big of one: you must have a folder within The only issue I can see with this is that there might be cases where the language files exist within modules but not in the main application. However, I think that's going to be a rare enough case to be okay here. If you're supporting languages for portions of the API you'd likely have some main language strings for the overall API, if only for the common error messages you'd want to be able to send back. Fixed in: 66d82f6 |
Thanks, it works, nice idea to check the directory, so the error is still raised if the lang file is missing and that's good, the user probably just forgot to create it. The only side-effect is the About the module, maybe
Notice if |
The controller try to use the idiom suggested by the browser, raising an error if the file doesn't exist, is this expected?
Shouldn't at least try to fallback to the default language in config? Or I'm missing something?
The text was updated successfully, but these errors were encountered: