Commit da3c19b3 authored by Gábor Hojtsy's avatar Gábor Hojtsy

#170334 by JirkaRybka: allow @count to be used in singular format_plural() values too

parent d8b17c9f
......@@ -955,10 +955,10 @@ function format_xml_elements($array) {
* A translated string.
*/
function format_plural($count, $singular, $plural, $args = array(), $langcode = NULL) {
$args['@count'] = $count;
if ($count == 1) {
return t($singular, $args);
return t($singular, $args, $langcode);
}
$args['@count'] = $count;
// get the plural index through the gettext formula
$index = (function_exists('locale_get_plural')) ? locale_get_plural($count, $langcode) : -1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment