withdraw static method

Future<ScLoanSuccess> withdraw(
  1. ScLoanInfo loanInfo
)

Implementation

static Future<ScLoanSuccess> withdraw(ScLoanInfo loanInfo) async {
  try {
    String? withdrawResponse =
        await _channel.invokeMethod('withdraw', <String, dynamic>{
      "interactionToken": loanInfo.interactionToken,
    });
    return ScLoanSuccess.fromJson(withdrawResponse ?? "{}");
  } on PlatformException catch (e) {
    throw e.toScLoanError;
  }
}