catchDioError<R extends APIResponse> method

Future<R> catchDioError<R extends APIResponse>(
  1. Future<R> future,
  2. R handle(
    1. DioError
    )
)
inherited

Catches and handles a DioError error in a future

  • future: The future
  • handle: The error handling function

Implementation

Future<R> catchDioError<R extends APIResponse>(
    Future<R> future, R Function(DioError) handle) {
  return catchError<R, DioError>(future, handle, options.errorHandling);
}