setPushClickCallback static method

void setPushClickCallback(
  1. Function successCallback, [
  2. String? companyId
])

Implementation

static void setPushClickCallback(Function successCallback,
    [String? companyId]) async {
  try {
    _channel.setMethodCallHandler((MethodCall call) async {
      if (call.method == 'pushClicked') {
        successCallback(call.arguments);
        log('webinstats_log : FlutterWIS : event triggered with : ${call.arguments}');
      }
    });
    await _channel
        .invokeMethod('setPushClickCallback', {'companyId': companyId});
  } catch (err) {
    log('webinstats_log : FlutterWIS : Exception : _setClickCallback : $err');
  }
}