smsAuth method

void smsAuth({
  1. required bool autoDismiss,
  2. int timeout = 5000,
  3. JVSMSListener? smsCallback,
})

Implementation

void smsAuth(
    {required bool autoDismiss,
    int timeout = 5000,
    JVSMSListener? smsCallback}) {
  print("$flutter_log" + "smsAuth");

  String method = "smsAuth";
  var repeatError = isRepeatRequest(method: method);
  if (repeatError == null) {
    _eventHanders.smsAuthIndex++;
    var map = {
      "autoDismiss": autoDismiss,
      "timeout": timeout,
      "smsAuthIndex": _eventHanders.smsAuthIndex
    };
    if (smsCallback != null) {
      _eventHanders.smsCallBackEventsMap[_eventHanders.smsAuthIndex] =
          smsCallback;
    }
    _channel.invokeMethod(method, map);
    requestQueue.remove(method);
  } else {
    print("$flutter_log" + repeatError.toString());
  }
}