From 19d3f23cd7e220fd9508fd3e1d5a016b31318e52 Mon Sep 17 00:00:00 2001 From: dalbodeule <11470513+dalbodeule@users.noreply.github.com> Date: Wed, 3 Jul 2024 22:33:25 +0900 Subject: [PATCH] chzzk livestream status handler fix --- src/main/kotlin/space/mori/chzzk_bot/chzzk/ChzzkHandler.kt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main/kotlin/space/mori/chzzk_bot/chzzk/ChzzkHandler.kt b/src/main/kotlin/space/mori/chzzk_bot/chzzk/ChzzkHandler.kt index b2fa90b..62d3de7 100644 --- a/src/main/kotlin/space/mori/chzzk_bot/chzzk/ChzzkHandler.kt +++ b/src/main/kotlin/space/mori/chzzk_bot/chzzk/ChzzkHandler.kt @@ -62,7 +62,7 @@ object ChzzkHandler { try { val streamInfo = getStreamInfo(it.channel.channelId) if (streamInfo.content.status == "OPEN" && !it.isActive) it.isActive(true, streamInfo) - if (streamInfo.content.status == "CLOSED" && it.isActive) it.isActive(false, streamInfo) + if (streamInfo.content.status == "CLOSE" && it.isActive) it.isActive(false, streamInfo) } catch(e: SocketTimeoutException) { logger.info("Timeout: ${it.channel.channelName} / ${e.stackTraceToString()}") } catch (e: Exception) { @@ -164,8 +164,6 @@ class UserHandler( } else { logger.info("${user.username} is offline.") listener.closeAsync() - - listener.sendChat("${user.username} 님! 방송 수고하셨습니다.") } } } \ No newline at end of file