From 7736ba3ca8ad33ee4044867fbf45d6a6adc9f0b6 Mon Sep 17 00:00:00 2001 From: nextel Date: Sun, 22 Sep 2019 17:03:12 +0300 Subject: [PATCH] add serde derive for optional field --- src/requests/kick_chat_member.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/requests/kick_chat_member.rs b/src/requests/kick_chat_member.rs index ea590d59..2ed54f0a 100644 --- a/src/requests/kick_chat_member.rs +++ b/src/requests/kick_chat_member.rs @@ -20,6 +20,7 @@ pub struct KickChatMember<'a> { ///Date when the user will be unbanned, unix time. If user is banned for /// more than 366 days or less than 30 seconds from the current time they /// are considered to be banned forever + #[serde(skip_serializing_if = "Option::is_none")] pub until_date: Option, }