mirror of
https://github.com/teloxide/teloxide.git
synced 2025-01-03 17:52:12 +01:00
Use MessageId
for reply_to_message_id
for some methods that were forgotten
This commit is contained in:
parent
84683d3a35
commit
9c2330897a
5 changed files with 13 additions and 9 deletions
|
@ -59,6 +59,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
- `Poll::total_voter_count` and `PollOption::voter_count` now use `u32` instead of `i32` ([#887][pr887])
|
||||
- `PollAnswer::option_ids` now use `u8` instead of `i32` ([#887][pr887])
|
||||
- Use `u32` for sizes and `Seconds` for timespans in `InlineQueryResult*` ([#887][pr887])
|
||||
- `SendGame::reply_to_message_id`, `SendSticker::reply_to_message_id` and `SendInvoice::reply_to_message_id` now use `MessageId` instead of `i32` ([#887][pr887])
|
||||
|
||||
[pr852]: https://github.com/teloxide/teloxide/pull/853
|
||||
[pr859]: https://github.com/teloxide/teloxide/pull/859
|
||||
|
|
|
@ -3437,7 +3437,7 @@ Schema(
|
|||
),
|
||||
Param(
|
||||
name: "reply_to_message_id",
|
||||
ty: Option(i32),
|
||||
ty: Option(RawTy("MessageId")),
|
||||
descr: Doc(md: "If the message is a reply, ID of the original message")
|
||||
),
|
||||
Param(
|
||||
|
@ -3798,7 +3798,7 @@ Schema(
|
|||
),
|
||||
Param(
|
||||
name: "reply_to_message_id",
|
||||
ty: Option(i32),
|
||||
ty: Option(RawTy("MessageId")),
|
||||
descr: Doc(md: "If the message is a reply, ID of the original message")
|
||||
),
|
||||
Param(
|
||||
|
@ -4049,7 +4049,7 @@ Schema(
|
|||
),
|
||||
Param(
|
||||
name: "reply_to_message_id",
|
||||
ty: Option(i32),
|
||||
ty: Option(RawTy("MessageId")),
|
||||
descr: Doc(md: "If the message is a reply, ID of the original message")
|
||||
),
|
||||
Param(
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
use serde::Serialize;
|
||||
|
||||
use crate::types::{Message, ReplyMarkup, ThreadId};
|
||||
use crate::types::{Message, MessageId, ReplyMarkup, ThreadId};
|
||||
|
||||
impl_payload! {
|
||||
/// Use this method to send a game. On success, the sent [`Message`] is returned.
|
||||
|
@ -26,7 +26,8 @@ impl_payload! {
|
|||
/// Protects the contents of sent messages from forwarding and saving
|
||||
pub protect_content: bool,
|
||||
/// If the message is a reply, ID of the original message
|
||||
pub reply_to_message_id: i32,
|
||||
#[serde(serialize_with = "crate::types::serialize_reply_to_message_id")]
|
||||
pub reply_to_message_id: MessageId,
|
||||
/// Pass _True_, if the message should be sent even if the specified replied-to message is not found
|
||||
pub allow_sending_without_reply: bool,
|
||||
/// A JSON-serialized object for an [inline keyboard]. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game.
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
use serde::Serialize;
|
||||
use url::Url;
|
||||
|
||||
use crate::types::{InlineKeyboardMarkup, LabeledPrice, Message, Recipient, ThreadId};
|
||||
use crate::types::{InlineKeyboardMarkup, LabeledPrice, Message, MessageId, Recipient, ThreadId};
|
||||
|
||||
impl_payload! {
|
||||
/// Use this method to send invoices. On success, the sent [`Message`] is returned.
|
||||
|
@ -71,7 +71,8 @@ impl_payload! {
|
|||
/// Protects the contents of sent messages from forwarding and saving
|
||||
pub protect_content: bool,
|
||||
/// If the message is a reply, ID of the original message
|
||||
pub reply_to_message_id: i32,
|
||||
#[serde(serialize_with = "crate::types::serialize_reply_to_message_id")]
|
||||
pub reply_to_message_id: MessageId,
|
||||
/// Pass _True_, if the message should be sent even if the specified replied-to message is not found
|
||||
pub allow_sending_without_reply: bool,
|
||||
/// A JSON-serialized object for an [inline keyboard]. If empty, one 'Pay `total price`' button will be shown. If not empty, the first button must be a Pay button.
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
use serde::Serialize;
|
||||
|
||||
use crate::types::{InputFile, Message, Recipient, ReplyMarkup, ThreadId};
|
||||
use crate::types::{InputFile, Message, MessageId, Recipient, ReplyMarkup, ThreadId};
|
||||
|
||||
impl_payload! {
|
||||
@[multipart = sticker]
|
||||
|
@ -29,7 +29,8 @@ impl_payload! {
|
|||
/// Protects the contents of sent messages from forwarding and saving
|
||||
pub protect_content: bool,
|
||||
/// If the message is a reply, ID of the original message
|
||||
pub reply_to_message_id: i32,
|
||||
#[serde(serialize_with = "crate::types::serialize_reply_to_message_id")]
|
||||
pub reply_to_message_id: MessageId,
|
||||
/// Pass _True_, if the message should be sent even if the specified replied-to message is not found
|
||||
pub allow_sending_without_reply: bool,
|
||||
/// Additional interface options. A JSON-serialized object for an [inline keyboard], [custom reply keyboard], instructions to remove reply keyboard or to force a reply from the user.
|
||||
|
|
Loading…
Reference in a new issue