Fix crash in unsupported message with buttons.

Fixes #6212.
This commit is contained in:
John Preston 2019-07-05 09:42:49 +02:00
parent 4a12e9798a
commit 3ca28c0cf9
1 changed files with 2 additions and 2 deletions

View File

@ -492,8 +492,8 @@ HistoryMessage::HistoryMessage(
UserId from,
const QString &postAuthor,
const TextWithEntities &textWithEntities)
: HistoryItem(history, id, flags, date, (flags & MTPDmessage::Flag::f_from_id) ? from : 0) {
createComponentsHelper(flags, replyTo, viaBotId, postAuthor, MTPReplyMarkup());
: HistoryItem(history, id, flags & ~MTPDmessage::Flag::f_reply_markup, date, (flags & MTPDmessage::Flag::f_from_id) ? from : 0) {
createComponentsHelper(flags & ~MTPDmessage::Flag::f_reply_markup, replyTo, viaBotId, postAuthor, MTPReplyMarkup());
setText(textWithEntities);
}