Fix streaming messages in topics.

This commit is contained in:
John Preston
2026-04-01 00:13:41 +07:00
parent fe199447d5
commit 0c3cec0da4
2 changed files with 4 additions and 1 deletions
@@ -1094,7 +1094,6 @@ void EmojiListWidget::fillCloudSearchSets() {
return;
}
const auto &sets = session().data().stickers().sets();
const auto test = session().isTestMode();
for (const auto setId : it->second) {
const auto setIt = sets.find(setId);
if (setIt == sets.end()) {
@@ -35,6 +35,9 @@ void HistoryStreamedDrafts::apply(
PeerId fromId,
TimeId when,
const MTPDsendMessageTextDraftAction &data) {
const auto replyToId = rootId
? FullMsgId(_history->peer->id, rootId)
: FullMsgId();
if (!rootId) {
rootId = Data::ForumTopic::kGeneralId;
}
@@ -56,6 +59,7 @@ void HistoryStreamedDrafts::apply(
.flags = MessageFlag::Local | MessageFlag::HasReplyInfo,
.from = fromId,
.replyTo = {
.messageId = replyToId,
.topicRootId = rootId,
},
.date = when,