mirror of
https://github.com/dalbodeule/chibot-chzzk-bot.git
synced 2025-06-09 07:18:22 +00:00
Merge pull request #28 from dalbodeule/develop
some debugs on WSTimerRoutes.kt
This commit is contained in:
commit
2f73204c6a
@ -11,6 +11,7 @@ import kotlinx.serialization.Serializable
|
|||||||
import org.koin.java.KoinJavaComponent.inject
|
import org.koin.java.KoinJavaComponent.inject
|
||||||
import org.slf4j.LoggerFactory
|
import org.slf4j.LoggerFactory
|
||||||
import space.mori.chzzk_bot.common.events.*
|
import space.mori.chzzk_bot.common.events.*
|
||||||
|
import space.mori.chzzk_bot.common.services.TimerConfigService
|
||||||
import space.mori.chzzk_bot.common.services.UserService
|
import space.mori.chzzk_bot.common.services.UserService
|
||||||
import java.util.concurrent.ConcurrentHashMap
|
import java.util.concurrent.ConcurrentHashMap
|
||||||
import java.util.concurrent.ConcurrentLinkedQueue
|
import java.util.concurrent.ConcurrentLinkedQueue
|
||||||
@ -49,6 +50,13 @@ fun Routing.wsTimerRoutes() {
|
|||||||
CoroutineScope(Dispatchers.Default).launch {
|
CoroutineScope(Dispatchers.Default).launch {
|
||||||
sendSerialized(TimerResponse(TimerType.STREAM_OFF.value, null))
|
sendSerialized(TimerResponse(TimerType.STREAM_OFF.value, null))
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
CoroutineScope(Dispatchers.Default).launch {
|
||||||
|
sendSerialized(TimerResponse(
|
||||||
|
TimerConfigService.getConfig(user)?.option ?: TimerType.STREAM_OFF.value,
|
||||||
|
null
|
||||||
|
))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user