checkStatus method

  1. @override
Future<Either<Failure, IncommePaymentStatus>> checkStatus({
  1. Map<String, dynamic>? param,
})
override

Implementation

@override
Future<Either<Failure, IncommePaymentStatus>> checkStatus({
  Map<String, dynamic>? param,
}) async {
  try {
    final response = await httpHandler.get(
      url: Api.payment.checkStatus,
      queryParameters: param,
      withAccessToken: true,
    );

    return Right(PaymentStatusDto.fromJson(response).jsonResult);
  } on Exception catch (error) {
    return Left(FailureResponse.mapExceptionToFailure(error));
  }
}