Skip to content

Commit d04dd43

Browse files
committed
feat(core): 允许不启用ws
1 parent 980a24c commit d04dd43

File tree

1 file changed

+2
-2
lines changed
  • simbot-component-onebot-v11/simbot-component-onebot-v11-core/src/commonMain/kotlin/love/forte/simbot/component/onebot/v11/core/bot/internal

1 file changed

+2
-2
lines changed

simbot-component-onebot-v11/simbot-component-onebot-v11-core/src/commonMain/kotlin/love/forte/simbot/component/onebot/v11/core/bot/internal/OneBotBotImpl.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,15 +299,15 @@ internal class OneBotBotImpl(
299299

300300
private inner class WsEventSession(
301301
val wsClient: HttpClient,
302-
val host: Url
302+
val wsHost: Url
303303
) {
304304
private val sessionJob = Job(this@OneBotBotImpl.job)
305305
private var session: DefaultWebSocketSession? = null
306306

307307
suspend fun createSession(): DefaultWebSocketSession {
308308
return wsClient.webSocketSession {
309309
url {
310-
takeFrom(host)
310+
takeFrom(wsHost)
311311
eventAccessToken?.also { bearerAuth(it) }
312312
}
313313
}

0 commit comments

Comments
 (0)