From 12ac227d2d003c40e5cb7e80b20ca95d24f30c2b Mon Sep 17 00:00:00 2001 From: InsanusMokrassar Date: Sun, 5 Feb 2023 23:18:14 +0600 Subject: [PATCH] small fix in request chat button --- .../inmo/tgbotapi/types/buttons/KeyboardButtonRequestChat.kt | 2 +- .../extensions/utils/types/buttons/ReplyKeyboardBuilder.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/buttons/KeyboardButtonRequestChat.kt b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/buttons/KeyboardButtonRequestChat.kt index e423daeb57..a78ed9bb78 100644 --- a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/buttons/KeyboardButtonRequestChat.kt +++ b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/buttons/KeyboardButtonRequestChat.kt @@ -33,6 +33,6 @@ data class KeyboardButtonRequestChat( @SerialName(botAdministratorRightsField) val botRightsInChat: ChatAdministratorRights? = null, @SerialName(botIsMemberField) - val botIsMember: Boolean = false + val botIsMember: Boolean? = null ) diff --git a/tgbotapi.utils/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/utils/types/buttons/ReplyKeyboardBuilder.kt b/tgbotapi.utils/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/utils/types/buttons/ReplyKeyboardBuilder.kt index 3b8cce77cf..a41a2cb0f1 100644 --- a/tgbotapi.utils/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/utils/types/buttons/ReplyKeyboardBuilder.kt +++ b/tgbotapi.utils/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/utils/types/buttons/ReplyKeyboardBuilder.kt @@ -235,7 +235,7 @@ inline fun ReplyKeyboardRowBuilder.requestChatButton( ownedBy: Boolean? = null, userRightsInChat: ChatAdministratorRights? = null, botRightsInChat: ChatAdministratorRights? = null, - botIsMember: Boolean = false + botIsMember: Boolean? = null ) = requestChatButton( text, KeyboardButtonRequestChat(