Compare commits

..

2 Commits

Author SHA1 Message Date
renovate[bot]
3f1a256e2a Merge 91837c0ea2 into a008d861da 2024-01-31 14:05:20 +00:00
renovate[bot]
91837c0ea2 Update dependency io.ktor:ktor-client-logging-jvm to v2.3.8 2024-01-31 14:05:17 +00:00
4 changed files with 5 additions and 24 deletions

View File

@@ -33,6 +33,6 @@ kotlin {
}
dependencies {
implementation 'io.ktor:ktor-client-logging-jvm:2.3.7'
implementation 'io.ktor:ktor-client-logging-jvm:2.3.8'
}

View File

@@ -18,5 +18,5 @@ dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation "dev.inmo:tgbotapi:$telegram_bot_api_version"
implementation 'io.ktor:ktor-client-logging-jvm:2.3.7'
implementation 'io.ktor:ktor-client-logging-jvm:2.3.8'
}

View File

@@ -1,9 +1,4 @@
import dev.inmo.kslog.common.KSLog
import dev.inmo.kslog.common.LogLevel
import dev.inmo.kslog.common.defaultMessageFormatter
import dev.inmo.kslog.common.setDefaultKSLog
import dev.inmo.micro_utils.coroutines.firstOf
import dev.inmo.micro_utils.coroutines.subscribeSafelyWithoutExceptions
import dev.inmo.micro_utils.fsm.common.State
import dev.inmo.tgbotapi.bot.ktor.telegramBot
import dev.inmo.tgbotapi.extensions.api.bot.setMyCommands
@@ -55,16 +50,6 @@ sealed interface UserRetrievingStep : State {
suspend fun main(args: Array<String>) {
val botToken = args.first()
val isDebug = args.getOrNull(2) == "debug"
if (isDebug) {
setDefaultKSLog(
KSLog { level: LogLevel, tag: String?, message: Any, throwable: Throwable? ->
println(defaultMessageFormatter(level, tag, message, throwable))
}
)
}
val bot = telegramBot(botToken)
val allowedAdmin = ChatId(args[1].toLong())
@@ -532,9 +517,5 @@ suspend fun main(args: Array<String>) {
BotCommand("rights_in_channel", "Trigger granular keyboard. Use with reply to user"),
scope = BotCommandScope.AllGroupChats
)
allUpdatesFlow.subscribeSafelyWithoutExceptions(this) {
println(it)
}
}.join()
}

View File

@@ -5,7 +5,7 @@ org.gradle.jvmargs=-Xmx2344m
kotlin_version=1.9.22
telegram_bot_api_version=10.1.0
micro_utils_version=0.20.34
telegram_bot_api_version=10.0.0
micro_utils_version=0.20.26
serialization_version=1.6.2
ktor_version=2.3.8
ktor_version=2.3.7