Execute an async block of code, catching any errors of the specified types and returning them as Err.
Err
If no errors are specified, the block will be executed as if it were passed to tryingAsync.
tryingAsync
The expected error types to catch from the block.
The block of code to execute.
The result of the block wrapped in an Ok, or an Err containing any error thrown by the block.
Ok
Execute an async block of code, catching any errors of the specified types and returning them as
Err
.If no errors are specified, the block will be executed as if it were passed to
tryingAsync
.