Merge pull request #31 from dalbodeule/develop

koin not started bug fix
This commit is contained in:
JinU Choi 2024-08-04 19:02:12 +09:00 committed by GitHub
commit 5c93476c34
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 9 deletions

View File

@ -1,8 +1,6 @@
package space.mori.chzzk_bot.chatbot.chzzk package space.mori.chzzk_bot.chatbot.chzzk
import io.github.cdimascio.dotenv.dotenv import io.github.cdimascio.dotenv.dotenv
import jdk.internal.net.http.common.Pair
import jdk.internal.net.http.common.Pair.pair
import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch import kotlinx.coroutines.launch
@ -11,7 +9,6 @@ import org.slf4j.LoggerFactory
import space.mori.chzzk_bot.common.events.CoroutinesEventBus import space.mori.chzzk_bot.common.events.CoroutinesEventBus
import space.mori.chzzk_bot.common.events.GetUserEvents import space.mori.chzzk_bot.common.events.GetUserEvents
import space.mori.chzzk_bot.common.events.GetUserType import space.mori.chzzk_bot.common.events.GetUserType
import space.mori.chzzk_bot.common.models.User
import space.mori.chzzk_bot.common.services.LiveStatusService import space.mori.chzzk_bot.common.services.LiveStatusService
import space.mori.chzzk_bot.common.services.UserService import space.mori.chzzk_bot.common.services.UserService
import xyz.r2turntrue.chzzk4j.Chzzk import xyz.r2turntrue.chzzk4j.Chzzk

View File

@ -22,12 +22,6 @@ val dotenv = dotenv {
} }
val logger: Logger = LoggerFactory.getLogger("main") val logger: Logger = LoggerFactory.getLogger("main")
val discord = Discord()
val connector = Connector
val chzzkConnector = ChzzkConnector
val chzzkHandler = ChzzkHandler
fun main(args: Array<String>) { fun main(args: Array<String>) {
val dispatcher = module { val dispatcher = module {
single { CoroutinesEventBus() } single { CoroutinesEventBus() }
@ -36,6 +30,12 @@ fun main(args: Array<String>) {
modules(dispatcher) modules(dispatcher)
} }
val discord = Discord()
val connector = Connector
val chzzkConnector = ChzzkConnector
val chzzkHandler = ChzzkHandler
discord.enable() discord.enable()
chzzkHandler.enable() chzzkHandler.enable()
chzzkHandler.runStreamInfo() chzzkHandler.runStreamInfo()