From d19413f8e6acfe0a01014d9abf44107e0d74e1d2 Mon Sep 17 00:00:00 2001 From: levlam Date: Thu, 29 Dec 2022 17:53:55 +0300 Subject: [PATCH] Add Message.general_forum_topic_hidden/general_forum_topic_unhidden. --- telegram-bot-api/Client.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/telegram-bot-api/Client.cpp b/telegram-bot-api/Client.cpp index b1bfee7..5c507a5 100644 --- a/telegram-bot-api/Client.cpp +++ b/telegram-bot-api/Client.cpp @@ -2071,9 +2071,12 @@ void Client::JsonMessage::store(JsonValueScope *scope) const { break; } case td_api::messageForumTopicIsHiddenToggled::ID: { - // auto content = static_cast(message_->content.get()); - // temporary; the topic is closed when it is hidden or unhidden - object("forum_topic_closed", JsonEmptyObject()); + auto content = static_cast(message_->content.get()); + if (content->is_hidden_) { + object("general_forum_topic_hidden", JsonEmptyObject()); + } else { + object("general_forum_topic_unhidden", JsonEmptyObject()); + } break; } case td_api::messagePinMessage::ID: {