update error type

This commit is contained in:
Lee 2024-04-16 23:32:06 +01:00
parent bf65923c00
commit e8993e0de6
2 changed files with 3 additions and 3 deletions

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

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