axios-error
Advanced tools
Comparing version 0.8.0 to 0.8.1
@@ -1,2 +0,2 @@ | ||
'use strict';var _util = require('util');var _util2 = _interopRequireDefault(_util);function _interopRequireDefault(obj) {return obj && obj.__esModule ? obj : { default: obj };} | ||
"use strict";var _util = _interopRequireDefault(require("util"));function _interopRequireDefault(obj) {return obj && obj.__esModule ? obj : { default: obj };} | ||
@@ -23,4 +23,4 @@ function indent(str) { | ||
err = _err; | ||
}var _err2 = | ||
err;const config = _err2.config,request = _err2.request,response = _err2.response; | ||
} | ||
const { config, request, response } = err; | ||
@@ -37,10 +37,10 @@ this.config = config; | ||
inspect(...args) { | ||
return this[_util2.default.inspect.custom](...args); | ||
return this[_util.default.inspect.custom](...args); | ||
} | ||
[_util2.default.inspect.custom]() { | ||
[_util.default.inspect.custom]() { | ||
let requestMessage = ''; | ||
if (this.config) {let | ||
data = this.config.data; | ||
if (this.config) { | ||
let { data } = this.config; | ||
@@ -47,0 +47,0 @@ try { |
{ | ||
"name": "axios-error", | ||
"description": "An axios error wrapper that aim to provide clear error message to the user", | ||
"version": "0.8.0", | ||
"engines": { | ||
"node": ">=6" | ||
}, | ||
"license": "MIT", | ||
"repository": { | ||
@@ -12,14 +9,17 @@ "type": "git", | ||
}, | ||
"license": "MIT", | ||
"version": "0.8.1", | ||
"main": "lib/index.js", | ||
"devDependencies": { | ||
"axios": "^0.19.0", | ||
"axios-mock-adapter": "^1.17.0" | ||
}, | ||
"keywords": [ | ||
"axios", | ||
"http", | ||
"error" | ||
"error", | ||
"http" | ||
], | ||
"devDependencies": { | ||
"axios": "^0.19.0", | ||
"axios-mock-adapter": "^1.15.0" | ||
"engines": { | ||
"node": ">=8" | ||
}, | ||
"gitHead": "62a2ec0cb939605bf01a6054b9ccce9f9bb8e1d7" | ||
"gitHead": "622f5664634c26e752e4e54bd32dbc773271390f" | ||
} |
10770