Support botTransactionPurposePaidMedia.

This commit is contained in:
levlam 2024-08-13 16:00:42 +03:00
parent af5f55b206
commit 6478c25096

View File

@ -4116,8 +4116,13 @@ class Client::JsonStarTransactionPartner final : public td::Jsonable {
} }
break; break;
} }
case td_api::botTransactionPurposePaidMedia::ID: case td_api::botTransactionPurposePaidMedia::ID: {
auto purpose = static_cast<const td_api::botTransactionPurposePaidMedia *>(source_user->purpose_.get());
object("paid_media", td::json_array(purpose->media_, [client = client_](auto &media) {
return JsonPaidMedia(media.get(), client);
}));
break; break;
}
default: default:
UNREACHABLE(); UNREACHABLE();
} }