Merge pull request #109 from teloxide/edited_message_is_too_long

Add `EditedMessageIsTooLong` error
This commit is contained in:
Hirrolot 2021-08-21 21:58:00 -07:00 committed by GitHub
commit 606a2fd634
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 0 deletions

View file

@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [unreleased] ## [unreleased]
- Add `EditedMessageIsTooLong` error [#109][pr109]
[pr109]: https://github.com/teloxide/teloxide-core/pull/109
## 0.3.3 ## 0.3.3
### Fixed ### Fixed

View file

@ -167,6 +167,22 @@ pub enum ApiError {
#[serde(rename = "Bad Request: message is too long")] #[serde(rename = "Bad Request: message is too long")]
MessageIsTooLong, MessageIsTooLong,
/// Occurs when bot tries to edit a message with text size greater then
/// 4096 symbols.
///
/// May happen in methods:
/// 1. [`EditMessageText`]
/// 2. [`EditMessageTextInline`]
/// 3. [`EditMessageCaption`]
/// 4. [`EditMessageCaptionInline`]
///
/// [`EditMessageText`]: crate::payloads::EditMessageText
/// [`EditMessageTextInline`]: crate::payloads::EditMessageTextInline
/// [`EditMessageCaption`]: crate::payloads::EditMessageCaption
/// [`EditMessageCaptionInline`]: crate::payloads::EditMessageCaptionInline
#[serde(rename = "Bad Request: MESSAGE_TOO_LONG")]
EditedMessageIsTooLong,
/// Occurs when bot tries to send media group with more than 10 items. /// Occurs when bot tries to send media group with more than 10 items.
/// ///
/// May happen in methods: /// May happen in methods: