1
0
Fork 0

Show votes count in translated text

This commit is contained in:
Lim Chee Aun 2023-08-17 14:08:26 +08:00
parent 6ddbcacd76
commit 6755626259

View file

@ -1169,7 +1169,16 @@ function Status({
getHTMLText(content) +
(poll?.options?.length
? `\n\nPoll:\n${poll.options
.map((option) => `- ${option.title}`)
.map(
(option) =>
`- ${option.title}${
option.votesCount >= 0
? ` (${option.votesCount} vote${
option.votesCount !== 1 ? 's' : ''
})`
: ''
}`,
)
.join('\n')}`
: '')
}