浏览代码

退出断开IM

wolyshaw 3 年之前
父节点
当前提交
5321b22471
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/components/live-broadcast/runtime.ts

+ 2 - 0
src/components/live-broadcast/runtime.ts

@@ -564,5 +564,7 @@ export const leaveIMRoom = async () => {
     // @ts-ignore
     await runtime.rtcClient?.leaveRoom(runtime.joinedRoom)
     runtime.joinedRoom = null
+    RongIMLib.disconnect()
+    runtime.imConnectStatus = 'disconnect'
   }
 }