The plural is wrongly specified.

It creates bugs as "1 vote" displayed in a poll instead of "0 votes".

In the fr.po, you need to replace "Plural-Forms: nplurals=2; plural=(n > 1);" by "Plural-Forms: nplurals=2; plural=(n != 1);"

Comments

alkahan’s picture

Assigned: Unassigned » alkahan
syllance’s picture

technically speaking, i think the bug is not on the plural form definition, as 0 should use the same form than 1 in our french case :)

the call to format_plural often use "1 " as singular, which in our case effectively displays 1 vote when there are 0.

if format_plural is called with "%count " even for singular form, then this is working.

unfortunately, the API doc for format_plural explicitely say to use distinct case for singular, and gives an example with "1 ", which is often used in the code, leaving few chances for the zero case to be managed the same way than the singular form.

Definition of plural forms indeed have to be defined as you say to avoid displaying 1 for 0 with code that explicitely use "1 " as singular.

Thanks

Damien Tournoud’s picture

Status: Active » Closed (works as designed)

Mainly fixed in core and main contributed modules.