@ackee/antonio
Advanced tools
Comparing version 4.0.0-alpha.3 to 4.0.0-alpha.4
# Changelog | ||
<a name="4.0.0-alpha.4"></a> | ||
## 4.0.0-alpha.4 (2020-05-11) | ||
### Fixed | ||
- 🐛 Fix error handling [[9c8b676](https://github.com/AckeeCZ/antonio/commit/9c8b676a277ad88b1b08ccf625ffcf912f394483)] | ||
<a name="4.0.0-alpha.3"></a> | ||
@@ -4,0 +12,0 @@ ## 4.0.0-alpha.3 (2020-05-11) |
export declare class HTTPError extends Error { | ||
name: string; | ||
response: any; | ||
constructor(response: Response); | ||
originalResponse: Response; | ||
response: BodyInit | null; | ||
constructor(response: Response, data: BodyInit | null); | ||
} |
import _defineProperty from "@babel/runtime/helpers/defineProperty"; | ||
export class HTTPError extends Error { | ||
constructor(response) { | ||
constructor(response, data) { | ||
// Set the message to the status text, such as Unauthorized, | ||
@@ -10,9 +10,12 @@ // with some fallbacks. This message should never be undefined. | ||
_defineProperty(this, "originalResponse", void 0); | ||
_defineProperty(this, "response", void 0); | ||
this.name = 'HTTPError'; | ||
this.response = response; | ||
this.originalResponse = response; | ||
this.response = data; | ||
} | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9tb2R1bGVzL2NvcmUvZXJyb3JzL2luZGV4LnRzIl0sIm5hbWVzIjpbIkhUVFBFcnJvciIsIkVycm9yIiwiY29uc3RydWN0b3IiLCJyZXNwb25zZSIsInN0YXR1c1RleHQiLCJTdHJpbmciLCJzdGF0dXMiLCJuYW1lIl0sIm1hcHBpbmdzIjoiO0FBQUEsT0FBTyxNQUFNQSxTQUFOLFNBQXdCQyxLQUF4QixDQUE4QjtBQUlqQ0MsRUFBQUEsV0FBVyxDQUFDQyxRQUFELEVBQXFCO0FBQzVCO0FBQ0E7QUFDQSxVQUNJQSxRQUFRLENBQUNDLFVBQVQsSUFDSUMsTUFBTSxDQUFDRixRQUFR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BUaGlzIG1lc3NhZ2Ugc2hvdWxkIG5ldmVyIGJlIHVuZGVmaW5lZC5cbiAgICAgICAgc3VwZXIoXG4gICAgICAgICAgICByZXNwb25zZS5zdGF0dXNUZXh0IHx8XG4gICAgICAgICAgICAgICAgU3RyaW5nKHJlc3BvbnNlLnN0YXR1cyA9PT0gMCB8fCByZXNwb25zZS5zdGF0dXMgPyByZXNwb25zZS5zdGF0dXMgOiAnVW5rbm93biByZXNwb25zZSBlcnJvcicpLFxuICAgICAgICApO1xuICAgICAgICB0aGlzLm5hbWUgPSAnSFRUUEVycm9yJztcbiAgICAgICAgdGhpcy5vcmlnaW5hbFJlc3BvbnNlID0gcmVzcG9uc2U7XG4gICAgICAgIHRoaXMucmVzcG9uc2UgPSBkYXRhO1xuICAgIH1cbn1cbiJdfQ== |
@@ -32,9 +32,9 @@ import { HTTPError } from './errors'; | ||
const response = await fetch(request); | ||
const data = await parseResponse(config.responseType, response); | ||
if (!response.ok) { | ||
// TODO: try response.error instead | ||
throw new HTTPError(response); | ||
throw new HTTPError(response, data); | ||
} | ||
const data = await parseResponse(config.responseType, response); | ||
return { | ||
@@ -46,2 +46,2 @@ request, | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9tb2R1bGVzL2NvcmUvcmVxdWVzdC50cyJdLCJuYW1lcyI6WyJIVFRQRXJyb3IiLCJjcmVhdGVSZXF1ZXN0VXJsIiwiZm9ybWF0UmVxdWVzdEJvZHkiLCJzZXRSZXF1ZXN0SGVhZGVycyIsInBhcnNlUmVzcG9uc2UiLCJtZXJnZUNvbmZpZyIsInJlcXVlc3QiLCJtZXRob2QiLCJyZXF1ZXN0VXJsIiwiYm9keSIsInJlcXVlc3RDb25maWciLCJkZWZhdWx0UmVxdWVzdENvbmZpZyIsImNvbmZpZyIsInVybCIsIm1vZGUiLCJjcmVkZW50aWFscyIsImNhY2hlIiwicmVk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ICAgIHRocm93IG5ldyBIVFRQRXJyb3IocmVzcG9uc2UsIGRhdGEpO1xuICAgIH1cbiAgICByZXR1cm4ge1xuICAgICAgICByZXF1ZXN0LFxuICAgICAgICByZXNwb25zZSxcbiAgICAgICAgZGF0YSxcbiAgICB9O1xufVxuIl19 |
{ | ||
"name": "@ackee/antonio", | ||
"version": "4.0.0-alpha.3", | ||
"version": "4.0.0-alpha.4", | ||
"description": "A HTTP client built on fetch with axios-like API.", | ||
@@ -5,0 +5,0 @@ "main": "es/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73955
42
497