mirror of
https://github.com/teloxide/teloxide.git
synced 2024-12-22 14:35:36 +01:00
Remove sticker_format
parameter from CreateNewStickerSet
This commit is contained in:
parent
590d46477f
commit
2655607320
5 changed files with 5 additions and 14 deletions
|
@ -3783,11 +3783,6 @@ Schema(
|
|||
ty: ArrayOf(RawTy("InputSticker")),
|
||||
descr: Doc(md: "A JSON-serialized list of 1-50 initial stickers to be added to the sticker set")
|
||||
),
|
||||
Param(
|
||||
name: "sticker_format",
|
||||
ty: RawTy("StickerFormat"),
|
||||
descr: Doc(md: "Format of the sticker, must be one of “static”, “animated”, “video”")
|
||||
),
|
||||
Param(
|
||||
name: "sticker_type",
|
||||
ty: Option(RawTy("StickerType")),
|
||||
|
|
|
@ -6,7 +6,7 @@ use crate::{
|
|||
requests::{JsonRequest, MultipartRequest},
|
||||
types::{
|
||||
BotCommand, ChatId, ChatPermissions, InlineQueryResult, InputFile, InputMedia,
|
||||
InputSticker, LabeledPrice, MessageId, Recipient, StickerFormat, ThreadId, UserId,
|
||||
InputSticker, LabeledPrice, MessageId, Recipient, ThreadId, UserId,
|
||||
},
|
||||
Bot,
|
||||
};
|
||||
|
@ -1189,7 +1189,6 @@ impl Requester for Bot {
|
|||
name: N,
|
||||
title: T,
|
||||
stickers: S,
|
||||
sticker_format: StickerFormat,
|
||||
) -> Self::CreateNewStickerSet
|
||||
where
|
||||
N: Into<String>,
|
||||
|
@ -1198,7 +1197,7 @@ impl Requester for Bot {
|
|||
{
|
||||
Self::CreateNewStickerSet::new(
|
||||
self.clone(),
|
||||
payloads::CreateNewStickerSet::new(user_id, name, title, stickers, sticker_format),
|
||||
payloads::CreateNewStickerSet::new(user_id, name, title, stickers),
|
||||
)
|
||||
}
|
||||
|
||||
|
|
|
@ -1308,11 +1308,11 @@ macro_rules! requester_forward {
|
|||
(@method create_new_sticker_set $body:ident $ty:ident) => {
|
||||
type CreateNewStickerSet = $ty![CreateNewStickerSet];
|
||||
|
||||
fn create_new_sticker_set<N, T, S>(&self, user_id: UserId, name: N, title: T, stickers: S, sticker_format: StickerFormat) -> Self::CreateNewStickerSet where N: Into<String>,
|
||||
fn create_new_sticker_set<N, T, S>(&self, user_id: UserId, name: N, title: T, stickers: S) -> Self::CreateNewStickerSet where N: Into<String>,
|
||||
T: Into<String>,
|
||||
S: IntoIterator<Item = InputSticker> {
|
||||
let this = self;
|
||||
$body!(create_new_sticker_set this (user_id: UserId, name: N, title: T, stickers: S, sticker_format: StickerFormat))
|
||||
$body!(create_new_sticker_set this (user_id: UserId, name: N, title: T, stickers: S))
|
||||
}
|
||||
};
|
||||
(@method add_sticker_to_set $body:ident $ty:ident) => {
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
use serde::Serialize;
|
||||
|
||||
use crate::types::{InputSticker, StickerFormat, StickerType, True, UserId};
|
||||
use crate::types::{InputSticker, StickerType, True, UserId};
|
||||
|
||||
impl_payload! {
|
||||
/// Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. Returns True on success.
|
||||
|
@ -17,8 +17,6 @@ impl_payload! {
|
|||
pub title: String [into],
|
||||
/// A JSON-serialized list of 1-50 initial stickers to be added to the sticker set
|
||||
pub stickers: Vec<InputSticker> [collect],
|
||||
/// Format of the sticker, must be one of “static”, “animated”, “video”
|
||||
pub sticker_format: StickerFormat,
|
||||
}
|
||||
optional {
|
||||
/// Type of stickers in the set, pass “regular”, “mask”, or “custom_emoji”. By default, a regular sticker set is created.
|
||||
|
|
|
@ -1071,7 +1071,6 @@ pub trait Requester {
|
|||
name: N,
|
||||
title: T,
|
||||
stickers: S,
|
||||
sticker_format: StickerFormat,
|
||||
) -> Self::CreateNewStickerSet
|
||||
where
|
||||
N: Into<String>,
|
||||
|
|
Loading…
Reference in a new issue