From 5a487f303f61322b89c13bfc455bbb4075aca3c9 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Wed, 2 Oct 2019 15:21:00 +0200 Subject: [PATCH] use amount instead of count as `_t` variable, count has special meaning --- src/components/views/rooms/MemberInfo.js | 8 ++++---- src/i18n/strings/en_EN.json | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/components/views/rooms/MemberInfo.js b/src/components/views/rooms/MemberInfo.js index 1757ee4b7b1..5aa3326abe2 100644 --- a/src/components/views/rooms/MemberInfo.js +++ b/src/components/views/rooms/MemberInfo.js @@ -376,10 +376,10 @@ module.exports = createReactClass({ }, eventsToRedact); } - const count = eventsToRedact.length; + const amount = eventsToRedact.length; const user = this.props.member.name; - if (count === 0) { + if (amount === 0) { const InfoDialog = sdk.getComponent("dialogs.InfoDialog"); Modal.createTrackedDialog('No user messages found to remove', '', InfoDialog, { title: _t("No recent messages by %(user)s found", {user}), @@ -395,10 +395,10 @@ module.exports = createReactClass({ title: _t("Remove recent messages by %(user)s", {user}), description:
-

{ _t("You are about to remove %(count)s messages by %(user)s. This cannot be undone. Do you wish to continue?", {count, user}) }

+

{ _t("You are about to remove %(amount)s message(s) by %(user)s. This cannot be undone. Do you wish to continue?", {amount: amount, user}) }

{ _t("For a large amount of messages, this might take some time. Please don't refresh your client in the meantime.") }

, - button: _t("Remove %(count)s messages", {count}), + button: _t("Remove %(amount)s message(s)", {amount}), onFinished: resolve, }); }); diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index 5a683ce92d5..4384800986f 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -804,9 +804,9 @@ "No recent messages by %(user)s found": "No recent messages by %(user)s found", "Try scrolling up in the timeline to see if there are any earlier ones.": "Try scrolling up in the timeline to see if there are any earlier ones.", "Remove recent messages by %(user)s": "Remove recent messages by %(user)s", - "You are about to remove %(count)s messages by %(user)s. This cannot be undone. Do you wish to continue?|other": "You are about to remove %(count)s messages by %(user)s. This cannot be undone. Do you wish to continue?", + "You are about to remove %(amount)s message(s) by %(user)s. This cannot be undone. Do you wish to continue?": "You are about to remove %(amount)s message(s) by %(user)s. This cannot be undone. Do you wish to continue?", "For a large amount of messages, this might take some time. Please don't refresh your client in the meantime.": "For a large amount of messages, this might take some time. Please don't refresh your client in the meantime.", - "Remove %(count)s messages|other": "Remove %(count)s messages", + "Remove %(amount)s message(s)": "Remove %(amount)s message(s)", "Demote yourself?": "Demote yourself?", "You will not be able to undo this change as you are demoting yourself, if you are the last privileged user in the room it will be impossible to regain privileges.": "You will not be able to undo this change as you are demoting yourself, if you are the last privileged user in the room it will be impossible to regain privileges.", "Demote": "Demote",