updateTag static method

Future<void> updateTag(
  1. TagInfo? taginfo,
  2. dynamic finished(
    1. int? code
    )?
)

Implementation

static Future<void> updateTag(TagInfo? taginfo, Function(int? code)? finished) async {
  if (taginfo == null) {
    developer.log("updateTag fail: taginfo is null", name: "RongIMClient");
    return null;
  }
  Map map = {"tagId": taginfo.tagId, "tagName": taginfo.tagName, "count": taginfo.count, "timestamp": taginfo.timestamp};
  Map? result = await _channel.invokeMethod(RCMethodKey.UpdateTag, map);
  if (finished != null) {
    finished(result!["code"]);
  }
}