Skip to content

Chinese plural rule is broken #14627

@nickvergessen

Description

@nickvergessen
Unhandled promise rejection TypeError: "e is undefined"

    translate l10n.js:108
translate l10n.js:107
translatePlural l10n.js:156
…
update filesummary.js:224
setSummary filesummary.js:190
calculate filesummary.js:173
setFiles filelist.js:1311
reloadCallback filelist.js:2014
…

Also the summary %n files shows instead of being replaced with the number of files. Deleting all plural rules from all zh_CN.js files removes the error.
adding a second item into the arrays also works, so it seems that the plural rule somehow tries to use a wrong plural rule, because chinese only has 1 rule.

Maybe @rullzer you can help? I tried debugging it, but I fail to recompile the new file after js/core/l10n.js was modified.

It also breaks worse in other apps, when the plural string is required instead of being added afterwards: nextcloud/announcementcenter#146

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions