From 7e2b1094d966187be0603e742dba1ca5b59d0e62 Mon Sep 17 00:00:00 2001
From: Philipp Loose
Date: Wed, 30 Nov 2022 18:44:07 +0100
Subject: [PATCH] refactor: add missing types for static AxiosError.from method
---
index.d.ts | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/index.d.ts b/index.d.ts
index 82349769c7..4bcfa3dd0a 100644
--- a/index.d.ts
+++ b/index.d.ts
@@ -371,6 +371,14 @@ export class AxiosError extends Error {
status?: number;
toJSON: () => object;
cause?: Error;
+ static from(
+ error: Error | unknown,
+ code?: string,
+ config?: AxiosRequestConfig,
+ request?: any,
+ response?: AxiosResponse,
+ customProps?: object,
+): AxiosError;
static readonly ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
static readonly ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
static readonly ERR_BAD_OPTION = "ERR_BAD_OPTION";