[ticket/11959] Use the plurals system for the untrimmed language strings.

PHPBB3-11959
This commit is contained in:
Cesar G 2013-12-01 11:25:54 -08:00
parent 7e4b7a1542
commit 126ee37f66
2 changed files with 15 additions and 4 deletions

View file

@ -424,21 +424,27 @@ $lang = array_merge($lang, array(
'NOT_WATCHING_FORUM' => 'You are no longer subscribed to updates on this forum.',
'NOT_WATCHING_TOPIC' => 'You are no longer subscribed to this topic.',
'NOTIFICATIONS' => 'Notifications',
'NOTIFICATION_BOOKMARK' => '%1$s replied to the topic "%2$s" you have bookmarked.',
'NOTIFICATION_BOOKMARK' => array(
1 => '%1$s replied to the topic “%2$s” you have bookmarked.',
),
'NOTIFICATION_BOOKMARK_TRIMMED' => array(
2 => '%1$s and %3$d others replied to the topic “%2$s” you have bookmarked.',
),
'NOTIFICATION_GROUP_REQUEST' => '%1$s is requesting to join the group %2$s.',
'NOTIFICATION_GROUP_REQUEST_APPROVED' => 'Your request to join the group %1$s has been approved.',
'NOTIFICATION_PM' => '%1$s sent you a Private Message "%2$s".',
'NOTIFICATION_POST' => '%1$s replied to the topic "%2$s".',
'NOTIFICATION_POST' => array(
1 => '%1$s replied to the topic “%2$s”.',
),
'NOTIFICATION_POST_TRIMMED' => array(
2 => '%1$s and %3$d others replied to the topic “%2$s”',
),
'NOTIFICATION_POST_APPROVED' => 'Your post was approved "%2$s".',
'NOTIFICATION_POST_DISAPPROVED' => 'Your post "%1$s" was disapproved for reason: "%2$s".',
'NOTIFICATION_POST_IN_QUEUE' => 'A new post titled "%2$s" was posted by %1$s and needs approval.',
'NOTIFICATION_QUOTE' => '%1$s quoted you in the post "%2$s".',
'NOTIFICATION_QUOTE' => array(
1 => '%1$s quoted you in the post “%2$s”.',
),
'NOTIFICATION_QUOTE_TRIMMED' => array(
2 => '%1$s and %3$d quoted you in the post “%2$s”',
),

View file

@ -210,13 +210,18 @@ class post extends \phpbb\notification\type\base
if ($trimmed_responders_cnt)
{
$lang_key .= '_TRIMMED';
$lang_user_cnt = $trimmed_responders_cnt;
}
else
{
$lang_user_cnt = $responders_cnt;
}
return $this->user->lang(
$lang_key,
implode($this->user->lang['COMMA_SEPARATOR'], $usernames),
censor_text($this->get_data('topic_title')),
$trimmed_responders_cnt
$lang_user_cnt
);
}