2 Commits

Author SHA1 Message Date
fb8ab8d7aa bump version
All checks were successful
Publish Package / build (push) Successful in 20s
2024-04-16 23:32:17 +01:00
e8993e0de6 update error type 2024-04-16 23:32:06 +01:00
3 changed files with 4 additions and 4 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "mcutils-library", "name": "mcutils-library",
"version": "1.1.4", "version": "1.1.5",
"description": "", "description": "",
"main": "dist/index.js", "main": "dist/index.js",
"types": "dist/index.d.ts", "types": "dist/index.d.ts",

View File

@ -1,5 +1,5 @@
import axios from "axios"; import axios from "axios";
import { Error } from "../types/error"; import { McUtilsAPIError } from "../types/error";
export default class WebRequest { export default class WebRequest {
/** /**
@ -21,7 +21,7 @@ export default class WebRequest {
// Reject if the status code is not 200 // Reject if the status code is not 200
if (response.status !== 200) { if (response.status !== 200) {
reject(data as Error); reject(data as McUtilsAPIError);
return; return;
} }

View File

@ -1,4 +1,4 @@
export type Error = { export type McUtilsAPIError = {
/** /**
* The status of the error. * The status of the error.
*/ */