ApiCoreFunctions
Function: isProtocolError()
function isProtocolError(error, code?): error is ProtocolError;Defined in: packages/core/src/utils/errors.ts:48
Narrows an unknown thrown value to a protocol error.
Parameters
| Parameter | Type |
|---|---|
error | unknown |
code? | ProtocolErrorCode |
Returns
error is ProtocolError