From 9a9ca5381e6048c636f4a31546aecb03004ec701 Mon Sep 17 00:00:00 2001 From: dangered wolf Date: Mon, 20 May 2024 23:59:04 -0400 Subject: [PATCH] Fix localization bug with polls --- src/embed/status.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/embed/status.ts b/src/embed/status.ts index 40a6e83..e56df27 100644 --- a/src/embed/status.ts +++ b/src/embed/status.ts @@ -391,8 +391,7 @@ export const handleStatus = async ( /* Finally, add the footer of the poll with # of votes and time left */ str += '\n'; /* TODO: Localize time left */ str += i18next - .t('pollVotes') - .format({ voteCount: formatNumber(poll.total_votes), timeLeft: poll.time_left_en }); + .t('pollVotes', { voteCount: formatNumber(poll.total_votes), timeLeft: poll.time_left_en }) /* Check if the poll is ongoing and apply low TTL cache control. Yes, checking if this is a string is a hacky way to do this, but