Merge pull request #1046 from mhkafadar/fix/typo-in-errors

fix: typo in errors.rs ToMuchMessages
This commit is contained in:
Waffle Maybe 2024-04-12 17:24:00 +00:00 committed by GitHub
commit 384811ab4b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View file

@ -55,6 +55,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Use `Seconds` instead of `String` in `InlineQueryResultAudio` for `audio_duration` ([PR 994](https://github.com/teloxide/teloxide/pull/994)) - Use `Seconds` instead of `String` in `InlineQueryResultAudio` for `audio_duration` ([PR 994](https://github.com/teloxide/teloxide/pull/994))
- High CPU usage on network errors ([PR 1002](https://github.com/teloxide/teloxide/pull/1002), [Issue 780](https://github.com/teloxide/teloxide/issues/780)) - High CPU usage on network errors ([PR 1002](https://github.com/teloxide/teloxide/pull/1002), [Issue 780](https://github.com/teloxide/teloxide/issues/780))
- Fix app build errors when using items gated behind sqlite-storage with the feature sqlite-storage-rustls ([PR 1018](https://github.com/teloxide/teloxide/pull/1018)) - Fix app build errors when using items gated behind sqlite-storage with the feature sqlite-storage-rustls ([PR 1018](https://github.com/teloxide/teloxide/pull/1018))
- Fix typo in `ApiError::ToMuchMessages` variant (rename it to `TooMuchMessages`) ([PR 1046](https://github.com/teloxide/teloxide/pull/1046))
### Changed ### Changed

View file

@ -289,7 +289,7 @@ impl_api_error! {
/// 1. [`SendMediaGroup`] /// 1. [`SendMediaGroup`]
/// ///
/// [`SendMediaGroup`]: crate::payloads::SendMediaGroup /// [`SendMediaGroup`]: crate::payloads::SendMediaGroup
ToMuchMessages = "Bad Request: Too much messages to send as an album", TooMuchMessages = "Bad Request: Too much messages to send as an album",
/// Occurs when bot tries to answer an inline query with more than 50 /// Occurs when bot tries to answer an inline query with more than 50
/// results. /// results.
@ -861,7 +861,7 @@ mod tests {
("{\"data\": \"Bad Request: MESSAGE_TOO_LONG\"}", ApiError::EditedMessageIsTooLong), ("{\"data\": \"Bad Request: MESSAGE_TOO_LONG\"}", ApiError::EditedMessageIsTooLong),
( (
"{\"data\": \"Bad Request: Too much messages to send as an album\"}", "{\"data\": \"Bad Request: Too much messages to send as an album\"}",
ApiError::ToMuchMessages, ApiError::TooMuchMessages,
), ),
("{\"data\": \"Bad Request: RESULTS_TOO_MUCH\"}", ApiError::TooMuchInlineQueryResults), ("{\"data\": \"Bad Request: RESULTS_TOO_MUCH\"}", ApiError::TooMuchInlineQueryResults),
( (