User tests: Successful: Unsuccessful:
The admin component com_media had some hard coded English texts.
This PR changes the hard coded English texts to language strings
and adds the translations to administrator/language/en-GB/com_media.ini
Status | New | ⇒ | Pending |
Category | ⇒ | Administration com_media Language & Strings |
I found the hard coded text when I was looking for the "Media Provider not found" that a J4 user reported to me when they tried to use Media as Custom Field Type.
If a decision was made to not translate exception messages, then that could explain why these strings weren't translated yet :-)
It appears to be inconsistent even within the same file and peersonally I don't understand why everything isnt a translatable string.
For example cheeck out https://github.com/joomla/joomla-cms/blob/4.1-dev/plugins/filesystem/local/src/Adapter/LocalAdapter.php
A basic rule should be that the API throws a specific exception and the representation layer should catch it and display a meaningful error message. We tried to do this in the local adapter with the FileNotFoundException
for example. But looks like some slipped through our fingers.
some? 12/15 is not some
Labels |
Added:
Language Change
PBF
?
|
Thanks @brianteeman!
I have tested this item
Marking as a successful test as it does what it says. Maintainers can decide if we do want to translate exceptions and then hopefully come up with a plan to update all existing hard coded exception strings.
Thanks. If this PR gets accepted, then I'll fix more of those hard coded Exception errors in components when I find them.
I have tested this item
I have tested this item
Status | Pending | ⇒ | Ready to Commit |
RTC
Labels |
Added:
?
Removed: PBF |
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2022-04-21 19:51:24 |
Closed_By | ⇒ | rdeutz |
I may be wrong but my undeerstanding was that exception messages were not being translated