Ignore whitespaces in dice sending.

This commit is contained in:
John Preston 2020-03-30 23:53:10 +04:00
parent c2ff27793a
commit 9ef41062d3
1 changed files with 1 additions and 1 deletions
Telegram/SourceFiles/api

View File

@ -200,7 +200,7 @@ void SendExistingPhoto(
bool SendDice(Api::MessageToSend &message) {
static const auto kDiceString = QString::fromUtf8("\xF0\x9F\x8E\xB2");
if (message.textWithTags.text != kDiceString) {
if (message.textWithTags.text.midRef(0).trimmed() != kDiceString) {
return false;
}
const auto history = message.action.history;