mirror of
https://github.com/tdlight-team/tdlight-telegram-bot-api.git
synced 2024-11-27 14:16:49 +01:00
Add support for spoiler entities.
This commit is contained in:
parent
6ec2104b81
commit
6b137be127
@ -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<td_api::object_ptr<td_api::TextEntityType>> Client::get_text_entity_t
|
||||
if (type == "strikethrough") {
|
||||
return make_object<td_api::textEntityTypeStrikethrough>();
|
||||
}
|
||||
if (type == "spoiler") {
|
||||
return make_object<td_api::textEntityTypeSpoiler>();
|
||||
}
|
||||
if (type == "code") {
|
||||
return make_object<td_api::textEntityTypeCode>();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user