Remove replyTo from switchInlineBotButton in same peer

This commit is contained in:
root 2019-10-01 09:41:49 +02:00 committed by John Preston
parent 701e1d7b4d
commit 246ed43046
1 changed files with 1 additions and 2 deletions

View File

@ -1433,8 +1433,7 @@ bool HistoryWidget::notify_switchInlineBotButtonReceived(const QString &query, U
if (_history) {
TextWithTags textWithTags = { '@' + samePeerBot->username + ' ' + query, TextWithTags::Tags() };
MessageCursor cursor = { textWithTags.text.size(), textWithTags.text.size(), QFIXED_MAX };
auto replyTo = _history->peer->isUser() ? 0 : samePeerReplyTo;
_history->setLocalDraft(std::make_unique<Data::Draft>(textWithTags, replyTo, cursor, false));
_history->setLocalDraft(std::make_unique<Data::Draft>(textWithTags, 0, cursor, false));
applyDraft();
return true;
}