Merge pull request #250 from teloxide/fix_set_webhook_again

Fix `SetWebhook` request: make it multipart
This commit is contained in:
Waffle Maybe 2022-09-25 05:23:06 +04:00 committed by GitHub
commit 00165e64dc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View file

@ -20,6 +20,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
[pr244]: https://github.com/teloxide/teloxide-core/pull/246
### Fixed
- `SetWebhook` request can now properly send certificate ([#250][pr250])
[pr250]: https://github.com/teloxide/teloxide-core/pull/250
### Deprecated
- `AutoSend` adaptor ([#249][pr249])

View file

@ -20,7 +20,7 @@ impl Requester for Bot {
Self::GetUpdates::new(self.clone(), payloads::GetUpdates::new())
}
type SetWebhook = JsonRequest<payloads::SetWebhook>;
type SetWebhook = MultipartRequest<payloads::SetWebhook>;
fn set_webhook(&self, url: Url) -> Self::SetWebhook {
Self::SetWebhook::new(self.clone(), payloads::SetWebhook::new(url))