leaveChannel method

Future<NIMResult<void>> leaveChannel(
  1. {required String channelId,
  2. required bool offlineEnabled,
  3. String? customInfo}
)

离开频道 错误码如下: 10406:不在频道内

channelId 对应频道id offlineEnable 通知事件是否存离线 customInfo 操作者附加的自定义信息,透传给其他人,可缺省

Implementation

Future<NIMResult<void>> leaveChannel(
    {required String channelId,
    required bool offlineEnabled,
    String? customInfo}) {
  return _platform.leaveChannel(
      channelId: channelId,
      offlineEnabled: offlineEnabled,
      customInfo: customInfo);
}