From f644817c04c91f6d39b51e0f714763fae15f1575 Mon Sep 17 00:00:00 2001 From: InsanusMokrassar Date: Thu, 10 Nov 2022 20:53:12 +0600 Subject: [PATCH] Update HelloPlugin.kt --- bot/src/main/kotlin/dev/inmo/plagubot/HelloPlugin.kt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bot/src/main/kotlin/dev/inmo/plagubot/HelloPlugin.kt b/bot/src/main/kotlin/dev/inmo/plagubot/HelloPlugin.kt index 085722e..ecdf138 100644 --- a/bot/src/main/kotlin/dev/inmo/plagubot/HelloPlugin.kt +++ b/bot/src/main/kotlin/dev/inmo/plagubot/HelloPlugin.kt @@ -11,7 +11,7 @@ import dev.inmo.tgbotapi.extensions.behaviour_builder.expectations.waitText import dev.inmo.tgbotapi.extensions.behaviour_builder.expectations.waitTextMessage import dev.inmo.tgbotapi.extensions.behaviour_builder.triggers_handling.onCommand import dev.inmo.tgbotapi.extensions.behaviour_builder.triggers_handling.onUnhandledCommand -import dev.inmo.tgbotapi.types.ChatId +import dev.inmo.tgbotapi.types.IdChatIdentifier import kotlinx.coroutines.flow.first import kotlinx.serialization.SerialName import kotlinx.serialization.Serializable @@ -38,9 +38,9 @@ object HelloPlugin : Plugin { } private sealed interface InternalFSMState : State { - override val context: ChatId - data class DidntSaidHello(override val context: ChatId) : InternalFSMState - data class SaidHelloOnce(override val context: ChatId) : InternalFSMState + override val context: IdChatIdentifier + data class DidntSaidHello(override val context: IdChatIdentifier) : InternalFSMState + data class SaidHelloOnce(override val context: IdChatIdentifier) : InternalFSMState } override suspend fun BehaviourContextWithFSM.setupBotPlugin(koin: Koin) {