Add sendPaidMedia.payload.

This commit is contained in:
levlam 2024-08-28 12:13:10 +03:00
parent f8c757d07d
commit 3fdee61a88

View File

@ -10400,9 +10400,10 @@ td::Status Client::process_send_paid_media_query(PromisedQueryPtr &query) {
int32 star_count = get_integer_arg(query.get(), "star_count", 0, 0, 1000000000); int32 star_count = get_integer_arg(query.get(), "star_count", 0, 0, 1000000000);
TRY_RESULT(paid_media, get_paid_media(query.get(), "media")); TRY_RESULT(paid_media, get_paid_media(query.get(), "media"));
TRY_RESULT(caption, get_caption(query.get())); TRY_RESULT(caption, get_caption(query.get()));
auto payload = query->arg("payload").str();
auto show_caption_above_media = to_bool(query->arg("show_caption_above_media")); auto show_caption_above_media = to_bool(query->arg("show_caption_above_media"));
do_send_message(make_object<td_api::inputMessagePaidMedia>(star_count, std::move(paid_media), std::move(caption), do_send_message(make_object<td_api::inputMessagePaidMedia>(star_count, std::move(paid_media), std::move(caption),
show_caption_above_media, td::string()), show_caption_above_media, payload),
std::move(query)); std::move(query));
return td::Status::OK(); return td::Status::OK();
} }