Fix SendChatAction return type

This commit is contained in:
Waffle 2021-03-29 13:47:34 +03:00
parent 8cd8ac96d9
commit 528187d7e6
2 changed files with 4 additions and 2 deletions

View file

@ -9,11 +9,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixed ### Fixed
- `SendChatAction` output type `Message` => `True` ([#75][pr75])
- `GetChatAdministrators` output type `ChatMember` => `Vec<ChatMember>` ([#73][pr73]) - `GetChatAdministrators` output type `ChatMember` => `Vec<ChatMember>` ([#73][pr73])
- `reqwest` dependency bringing `native-tls` in even when `rustls` was selected ([#71][pr71]) - `reqwest` dependency bringing `native-tls` in even when `rustls` was selected ([#71][pr71])
[pr71]: https://github.com/teloxide/teloxide-core/pull/71 [pr71]: https://github.com/teloxide/teloxide-core/pull/71
[pr73]: https://github.com/teloxide/teloxide-core/pull/73 [pr73]: https://github.com/teloxide/teloxide-core/pull/73
[pr75]: https://github.com/teloxide/teloxide-core/pull/75
## [0.2.2] - 2020-03-22 ## [0.2.2] - 2020-03-22

View file

@ -8,7 +8,7 @@
// [`schema`]: https://github.com/WaffleLapkin/tg-methods-schema // [`schema`]: https://github.com/WaffleLapkin/tg-methods-schema
use serde::Serialize; use serde::Serialize;
use crate::types::{ChatAction, ChatId, Message}; use crate::types::{ChatAction, ChatId, True};
impl_payload! { impl_payload! {
/// Use this method when you need to tell the user that something is happening on the bot's side. The status is set for 5 seconds or less (when a message arrives from your bot, Telegram clients clear its typing status). Returns True on success. /// Use this method when you need to tell the user that something is happening on the bot's side. The status is set for 5 seconds or less (when a message arrives from your bot, Telegram clients clear its typing status). Returns True on success.
@ -19,7 +19,7 @@ impl_payload! {
/// ///
/// [ImageBot]: https://t.me/imagebot /// [ImageBot]: https://t.me/imagebot
#[derive(Debug, PartialEq, Eq, Hash, Clone, Serialize)] #[derive(Debug, PartialEq, Eq, Hash, Clone, Serialize)]
pub SendChatAction (SendChatActionSetters) => Message { pub SendChatAction (SendChatActionSetters) => True {
required { required {
/// Unique identifier for the target chat or username of the target channel (in the format `@channelusername`) /// Unique identifier for the target chat or username of the target channel (in the format `@channelusername`)
pub chat_id: ChatId [into], pub chat_id: ChatId [into],