From 6b137be127be166f81f5225f1bee5c06934953f1 Mon Sep 17 00:00:00 2001 From: levlam Date: Thu, 30 Dec 2021 14:44:21 +0300 Subject: [PATCH] Add support for spoiler entities. --- telegram-bot-api/Client.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/telegram-bot-api/Client.cpp b/telegram-bot-api/Client.cpp index 5c79ff9..71a7a2e 100644 --- a/telegram-bot-api/Client.cpp +++ b/telegram-bot-api/Client.cpp @@ -417,6 +417,9 @@ class Client::JsonEntity : public Jsonable { case td_api::textEntityTypeStrikethrough::ID: object("type", "strikethrough"); break; + case td_api::textEntityTypeSpoiler::ID: + object("type", "spoiler"); + break; case td_api::textEntityTypeCode::ID: object("type", "code"); break; @@ -5934,6 +5937,9 @@ td::Result> Client::get_text_entity_t if (type == "strikethrough") { return make_object(); } + if (type == "spoiler") { + return make_object(); + } if (type == "code") { return make_object(); }