You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
373 B

3 years ago
'use strict';
3 years ago
import utils from './../utils.js';
3 years ago
/**
* Determines whether the payload is an error thrown by Axios
*
* @param {*} payload The value to test
3 years ago
*
3 years ago
* @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
*/
3 years ago
export default function isAxiosError(payload) {
3 years ago
return utils.isObject(payload) && (payload.isAxiosError === true);
3 years ago
}