From 0c3cec0da42c70a6749d6a0bd3a1e022f8bfcd76 Mon Sep 17 00:00:00 2001 From: John Preston Date: Wed, 1 Apr 2026 00:13:41 +0700 Subject: [PATCH] Fix streaming messages in topics. --- Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp | 1 - Telegram/SourceFiles/history/history_streamed_drafts.cpp | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp b/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp index c0d4a7db49..4b7fab7d52 100644 --- a/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp +++ b/Telegram/SourceFiles/chat_helpers/emoji_list_widget.cpp @@ -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()) { diff --git a/Telegram/SourceFiles/history/history_streamed_drafts.cpp b/Telegram/SourceFiles/history/history_streamed_drafts.cpp index d719e81dcc..7459825658 100644 --- a/Telegram/SourceFiles/history/history_streamed_drafts.cpp +++ b/Telegram/SourceFiles/history/history_streamed_drafts.cpp @@ -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,