Method HandleAsync
HandleAsync(HttpContext, Exception)
Maps the specified exception to the ApiException that should be reported to the client.
Declaration
public ValueTask<ApiException?> HandleAsync(HttpContext httpContext, Exception exception)
Parameters
| Type | Name | Description |
|---|---|---|
| HttpContext | httpContext | The HTTP context of the request that threw the exception. |
| Exception | exception | The exception that was thrown. |
Returns
| Type | Description |
|---|---|
| ValueTask<ApiException> | The ApiException to report (which may be |