mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI-examples.git
synced 2025-12-05 05:45:39 +00:00
Compare commits
13 Commits
26.1.0
...
renovate/m
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ab45b92771 | ||
| ab85d3acb2 | |||
| 3c3262b9cc | |||
|
|
e378c6630c | ||
|
|
4eda93538e | ||
| 707ad9a160 | |||
| 68e9830a8f | |||
| 55ebdeadbc | |||
|
|
d4f3d4bc68 | ||
| b3d06c9773 | |||
| e6e3eabf97 | |||
| 47efedf311 | |||
| 8423b1377b |
@@ -1,3 +1,6 @@
|
||||
import dev.inmo.kslog.common.KSLog
|
||||
import dev.inmo.kslog.common.defaultMessageFormatter
|
||||
import dev.inmo.kslog.common.filter.filtered
|
||||
import dev.inmo.micro_utils.coroutines.subscribeLoggingDropExceptions
|
||||
import dev.inmo.tgbotapi.extensions.api.bot.getMe
|
||||
import dev.inmo.tgbotapi.extensions.api.send.withTypingAction
|
||||
@@ -10,7 +13,9 @@ import dev.inmo.tgbotapi.extensions.utils.withContentOrNull
|
||||
import dev.inmo.tgbotapi.types.ReplyParameters
|
||||
import dev.inmo.tgbotapi.types.message.abstracts.BusinessContentMessage
|
||||
import dev.inmo.tgbotapi.types.message.content.TextContent
|
||||
import dev.inmo.tgbotapi.utils.DefaultKTgBotAPIKSLog
|
||||
import dev.inmo.tgbotapi.utils.extensions.threadIdOrNull
|
||||
import kotlinx.coroutines.CancellationException
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.SupervisorJob
|
||||
import kotlinx.coroutines.currentCoroutineContext
|
||||
@@ -19,7 +24,10 @@ suspend fun activateResenderBot(
|
||||
token: String,
|
||||
print: (Any) -> Unit
|
||||
) {
|
||||
telegramBotWithBehaviourAndLongPolling(token, scope = CoroutineScope(currentCoroutineContext() + SupervisorJob())) {
|
||||
telegramBotWithBehaviourAndLongPolling(
|
||||
token,
|
||||
scope = CoroutineScope(currentCoroutineContext() + SupervisorJob()),
|
||||
) {
|
||||
onContentMessage(
|
||||
subcontextUpdatesFilter = MessageFilterByChat,
|
||||
initialFilter = { it !is BusinessContentMessage<*> || !it.sentByBusinessConnectionOwner }
|
||||
|
||||
@@ -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:3.1.0'
|
||||
implementation 'io.ktor:ktor-client-logging-jvm:3.2.3'
|
||||
}
|
||||
|
||||
@@ -5,9 +5,9 @@ org.gradle.jvmargs=-Xmx3148m
|
||||
kotlin.daemon.jvmargs=-Xmx3g -Xms500m
|
||||
|
||||
|
||||
kotlin_version=2.1.20
|
||||
telegram_bot_api_version=26.1.0
|
||||
micro_utils_version=0.25.7
|
||||
serialization_version=1.8.1
|
||||
ktor_version=3.1.3
|
||||
compose_version=1.8.0
|
||||
kotlin_version=2.2.0
|
||||
telegram_bot_api_version=27.1.2
|
||||
micro_utils_version=0.26.2
|
||||
serialization_version=1.9.0
|
||||
ktor_version=3.2.3
|
||||
compose_version=1.8.2
|
||||
|
||||
Reference in New Issue
Block a user