From e14d72306f92b122a22b9b76bea48b765e2f3b99 Mon Sep 17 00:00:00 2001 From: levlam Date: Fri, 4 Nov 2022 17:52:26 +0300 Subject: [PATCH] Improve actor of TopicCreated chat log event. --- td/telegram/DialogEventLog.cpp | 1 + td/telegram/ForumTopicInfo.h | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/td/telegram/DialogEventLog.cpp b/td/telegram/DialogEventLog.cpp index 6948ec451..69b771a54 100644 --- a/td/telegram/DialogEventLog.cpp +++ b/td/telegram/DialogEventLog.cpp @@ -368,6 +368,7 @@ static td_api::object_ptr get_chat_event_action_object( if (topic_info.is_empty()) { return nullptr; } + actor_dialog_id = topic_info.get_creator_dialog_id(); return td_api::make_object(topic_info.get_forum_topic_info_object(td)); } case telegram_api::channelAdminLogEventActionEditTopic::ID: { diff --git a/td/telegram/ForumTopicInfo.h b/td/telegram/ForumTopicInfo.h index a7cce8506..aa1ae03d0 100644 --- a/td/telegram/ForumTopicInfo.h +++ b/td/telegram/ForumTopicInfo.h @@ -55,6 +55,10 @@ class ForumTopicInfo { return top_thread_message_id_; } + DialogId get_creator_dialog_id() const { + return creator_dialog_id_; + } + bool is_outgoing() const { return is_outgoing_; }