fix double serialization

This commit is contained in:
p0lunin 2020-01-09 20:35:10 +02:00
parent a183494ea3
commit 1743c24026
53 changed files with 53 additions and 53 deletions

View file

@ -49,7 +49,7 @@ impl Request for AnswerCallbackQuery<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"answerCallbackQuery", "answerCallbackQuery",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -58,7 +58,7 @@ impl Request for AnswerInlineQuery<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"answerInlineQuery", "answerInlineQuery",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -42,7 +42,7 @@ impl Request for AnswerPreCheckoutQuery<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"answerPreCheckoutQuery", "answerPreCheckoutQuery",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -42,7 +42,7 @@ impl Request for AnswerShippingQuery<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"answerShippingQuery", "answerShippingQuery",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -30,7 +30,7 @@ impl Request for DeleteChatPhoto<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"deleteChatPhoto", "deleteChatPhoto",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for DeleteChatStickerSet<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"deleteChatStickerSet", "deleteChatStickerSet",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -38,7 +38,7 @@ impl Request for DeleteMessage<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"deleteMessage", "deleteMessage",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -28,7 +28,7 @@ impl Request for DeleteStickerFromSet<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"deleteStickerFromSet", "deleteStickerFromSet",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -25,7 +25,7 @@ impl Request for DeleteWebhook<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"deleteWebhook", "deleteWebhook",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -37,7 +37,7 @@ impl Request for EditMessageCaption<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"editMessageCaption", "editMessageCaption",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -37,7 +37,7 @@ impl Request for EditMessageLiveLocation<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"editMessageLiveLocation", "editMessageLiveLocation",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for EditMessageReplyMarkup<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"editMessageReplyMarkup", "editMessageReplyMarkup",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -39,7 +39,7 @@ impl Request for EditMessageText<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"editMessageText", "editMessageText",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -37,7 +37,7 @@ impl Request for ExportChatInviteLink<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"exportChatInviteLink", "exportChatInviteLink",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -37,7 +37,7 @@ impl Request for ForwardMessage<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"forwardMessage", "forwardMessage",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -30,7 +30,7 @@ impl Request for GetChat<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getChat", "getChat",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for GetChatAdministrators<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getChatAdministrators", "getChatAdministrators",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -31,7 +31,7 @@ impl Request for GetChatMember<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getChatMember", "getChatMember",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -29,7 +29,7 @@ impl Request for GetChatMembersCount<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getChatMembersCount", "getChatMembersCount",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -45,7 +45,7 @@ impl Request for GetFile<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getFile", "getFile",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -35,7 +35,7 @@ impl Request for GetGameHighScores<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getGameHighScores", "getGameHighScores",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -26,7 +26,7 @@ impl Request for GetMe<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getMe", "getMe",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -28,7 +28,7 @@ impl Request for GetStickerSet<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getStickerSet", "getStickerSet",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -74,7 +74,7 @@ impl Request for GetUpdates<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getUpdates", "getUpdates",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -34,7 +34,7 @@ impl Request for GetUserProfilePhotos<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getUserProfilePhotos", "getUserProfilePhotos",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -25,7 +25,7 @@ impl Request for GetWebhookInfo<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"getWebhookInfo", "getWebhookInfo",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -38,7 +38,7 @@ impl Request for KickChatMember<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"kickChatMember", "kickChatMember",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -29,7 +29,7 @@ impl Request for LeaveChat<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"leaveChat", "leaveChat",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -37,7 +37,7 @@ impl Request for PinChatMessage<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"pinChatMessage", "pinChatMessage",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -54,7 +54,7 @@ impl Request for PromoteChatMember<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"promoteChatMember", "promoteChatMember",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -39,7 +39,7 @@ impl Request for RestrictChatMember<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"restrictChatMember", "restrictChatMember",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -76,7 +76,7 @@ impl Request for SendChatAction<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendChatAction", "sendChatAction",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -46,7 +46,7 @@ impl Request for SendContact<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendContact", "sendContact",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -39,7 +39,7 @@ impl Request for SendGame<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendGame", "sendGame",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -83,7 +83,7 @@ impl Request for SendInvoice<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendInvoice", "sendInvoice",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -45,7 +45,7 @@ impl Request for SendLocation<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendLocation", "sendLocation",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -53,7 +53,7 @@ impl Request for SendMessage<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendMessage", "sendMessage",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -43,7 +43,7 @@ impl Request for SendPoll<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendPoll", "sendPoll",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -52,7 +52,7 @@ impl Request for SendVenue<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendVenue", "sendVenue",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -36,7 +36,7 @@ impl Request for SetChatAdministratorCustomTitle<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setChatAdministratorCustomTitle", "setChatAdministratorCustomTitle",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for SetChatDescription<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setChatDescription", "setChatDescription",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for SetChatPermissions<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"sendChatPermissions", "sendChatPermissions",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -33,7 +33,7 @@ impl Request for SetChatPhoto<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setChatPhoto", "setChatPhoto",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -34,7 +34,7 @@ impl Request for SetChatStickerSet<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setChatStickerSet", "setChatStickerSet",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for SetChatTitle<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setChatTitle", "setChatTitle",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -41,7 +41,7 @@ impl Request for SetGameScore<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setGameScore", "setGameScore",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -30,7 +30,7 @@ impl Request for SetStickerPositionInSet<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setStickerPositionInSet", "setStickerPositionInSet",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -57,7 +57,7 @@ impl Request for SetWebhook<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"setWebhook", "setWebhook",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for StopMessageLiveLocation<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"stopMessageLiveLocation", "stopMessageLiveLocation",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -33,7 +33,7 @@ impl Request for StopPoll<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"stopPoll", "stopPoll",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -33,7 +33,7 @@ impl Request for UnbanChatMember<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"unbanChatMember", "unbanChatMember",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -31,7 +31,7 @@ impl Request for UnpinChatMessage<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"unpinChatMessage", "unpinChatMessage",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }

View file

@ -32,7 +32,7 @@ impl Request for UploadStickerFile<'_> {
self.bot.client(), self.bot.client(),
self.bot.token(), self.bot.token(),
"uploadStickerFile", "uploadStickerFile",
&serde_json::to_string(self).unwrap(), &self,
) )
.await .await
} }