From bc771a3b2f0e3e704e9b442034e86e231c81b7c5 Mon Sep 17 00:00:00 2001 From: levlam Date: Mon, 30 Dec 2024 18:38:12 +0300 Subject: [PATCH] Update TDLib to 1.8.42. --- td | 2 +- telegram-bot-api/Client.cpp | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/td b/td index 7648b99..ef580cd 160000 --- a/td +++ b/td @@ -1 +1 @@ -Subproject commit 7648b99d81d36d44bae3ca6c514a816a2fe8cfd1 +Subproject commit ef580cd3dd0e5223c2be503342dc29e128be866e diff --git a/telegram-bot-api/Client.cpp b/telegram-bot-api/Client.cpp index be10b7a..49c47a8 100644 --- a/telegram-bot-api/Client.cpp +++ b/telegram-bot-api/Client.cpp @@ -3389,6 +3389,10 @@ void Client::JsonMessage::store(td::JsonValueScope *scope) const { break; case td_api::messageGift::ID: break; + case td_api::messageUpgradedGift::ID: + break; + case td_api::messageRefundedUpgradedGift::ID: + break; default: UNREACHABLE(); } @@ -6666,8 +6670,8 @@ void Client::check_business_connection_chat_id(const td::string &business_connec } auto chat_id = r_chat_id.move_as_ok(); check_business_connection(business_connection_id, std::move(query), - [chat_id, on_success = std::move(on_success)]( - const BusinessConnection *business_connection, PromisedQueryPtr query) mutable { + [chat_id, on_success = std::move(on_success)](const BusinessConnection *business_connection, + PromisedQueryPtr query) mutable { on_success(business_connection, chat_id, std::move(query)); }); } @@ -8577,7 +8581,7 @@ td::Result> Client::get_inlin CHECK(input_message_content != nullptr); return make_object( - id, url, hide_url, title, description, thumbnail_url, thumbnail_width, thumbnail_height, + id, hide_url ? td::string() : url, title, description, thumbnail_url, thumbnail_width, thumbnail_height, std::move(reply_markup), std::move(input_message_content)); } if (type == "audio") { @@ -11382,7 +11386,7 @@ td::Status Client::process_send_gift_query(PromisedQueryPtr &query) { get_input_entities(query.get(), "text_entities"))); check_user(user_id, std::move(query), [this, gift_id, user_id, text = std::move(text)](PromisedQueryPtr query) mutable { - send_request(make_object(gift_id, user_id, std::move(text), false), + send_request(make_object(gift_id, user_id, std::move(text), false, false), td::make_unique(std::move(query))); }); return td::Status::OK(); @@ -14284,6 +14288,10 @@ bool Client::need_skip_update_message(int64 chat_id, const object_ptr