showChannel static method
Implementation
static Future<bool> showChannel(
String channelId,
{
Function(int? errorCode, String? errorMessage)? errorCallback
}) async
{
if (!_isInitialized(errorCallback: errorCallback)) { return false; }
if (!_checkAuthInfo(errorCallback: errorCallback)) { return false; }
try {
Map<String, dynamic> body = Map.from({});
String url = "/channels/$channelId/show";
await HttpUtil.postJson(url, body);
return true;
} on TPException catch(e) {
Logger.log("${e.getCode()}, ${e.getMessage()}");
errorCallback?.call(e.getCode(), e.getMessage());
} catch(e){
Logger.log("$e");
errorCallback?.call(-1, e.toString());
}
return false;
}