[wp-trac] [WordPress Trac] #37819: _load_textdomain_just_in_time() is really not nice with alternative translations
WordPress Trac
noreply at wordpress.org
Mon Sep 19 07:14:46 UTC 2016
#37819: _load_textdomain_just_in_time() is really not nice with alternative
translations
--------------------------------------+------------------------------
Reporter: imath | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: I18N | Version: 4.6
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses:
--------------------------------------+------------------------------
Changes (by imath):
* keywords: has-patch needs-unit-tests => has-patch has-unit-tests
Comment:
Sorry to insist on this ticket @swissspidy @ocean90 but i really think
this issue should be fixed.
So i'm adding some other files to this ticket:
- 37819.fixRefreshed.diff is a refreshed version to latest trunk of my
initial patch
- 37819.unittestOnly.diff only contains a unit test so that you can see
without the fix applied the issue (3rd assertion will fail).
- 37819.fix&unittest.diff contains the unit test and the fix and you'll
see that all assertions are then Ok.
- mofiles.tar contains the mo files i had to create to build the unit
test.
I had to edit the dummy plugin so that it includes a new string. I wanted
to show you that the patch not only fixes custom language packs loading
but also why it is imho a real improvement for user.
You'll see that the custom language pack doesn't include one of the
string, it's on purpose. It's to show that even if a custom language pack
has not been updated, the string will keep on being translated for the
user as the languages/plugin.mo is not unloaded but the custom mo is
merged with it for the strings that are in common.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/37819#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list