onError method

Future<SdkError?> onError(
  1. HttpRequest req,
  2. SdkError err
)

Observes or replaces an error produced from a thrown exception path.

This does not run for contract failures that already produced an unsuccessful response object.

Implementation

Future<SdkError?> onError(HttpRequest req, SdkError err) async => null;