waitForResponse method

Future waitForResponse()

This will wait for the response from Payhere native sdk.

Implementation

Future waitForResponse() {
  Completer completer = Completer();
  pF.setMethodCallHandler((call) async {
    result = call.arguments.toString();
    completer.complete();
  });
  return completer.future;
}