Commit dad01d3
committed
Fix for wrong plurals with multiple domains
When translations from different catalogs are being merged, there is a
workaround to copy the `plurals()` function from the catalog to the combined
`translations` object. If the locale catalog doesn't exist for a
particular domain, a default value is copied, overriding the proper
`plurals()`function. This results in the plural version of a string not
being translated for languages with different plural values.
See for instance `test_gettext.py::test_plurals_different_domains`: the
Japanese locale exists only in the `messages` domain (`translations`
folder) but not on the `myapp` one (`translations_different_domain`
folder).
First reported in ckan/ckan#82581 parent 38a3458 commit dad01d3
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
630 | 630 | | |
631 | 631 | | |
632 | 632 | | |
633 | | - | |
| 633 | + | |
634 | 634 | | |
635 | 635 | | |
636 | 636 | | |
| |||
0 commit comments