Check if an error is caused by user calling cancel() in REST API.
Parameters
error: unknown
The unknown exception to be checked.
Returns error is CanceledError
A boolean indicating if the error was from an upload cancellation
Note
This function works ONLY for errors thrown by REST API. For GraphQL APIs, use client.isCancelError(error)
instead. client is generated from generateClient() API from aws-amplify/api.
Check if an error is caused by user calling
cancel()
in REST API.