enableNotification method Null safety

Future<NIMResult<void>> enableNotification(
  1. {required bool enableRegularNotification,
  2. required bool enableRevokeMessageNotification}
)

配置消息提醒,仅支持 Android 平台,iOS平台请关闭通知权限

[enableRegularNotification] - 普通消息提醒开关

[enableRevokeMessageNotification] - 消息撤回是否提醒

Implementation

Future<NIMResult<void>> enableNotification({
  required bool enableRegularNotification,
  required bool enableRevokeMessageNotification,
}) {
  return _platform.enableNotificationAndroid(
    enableRegularNotification: enableRegularNotification,
    enableRevokeMessageNotification: enableRevokeMessageNotification,
  );
}