From ac89bdeee1f7f357beca58b363cf31a5e62410c9 Mon Sep 17 00:00:00 2001 From: Yun Shan Date: Mon, 16 Sep 2024 13:21:45 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E8=AF=95=E5=89=8D=E6=89=93=E5=8D=B0?= =?UTF-8?q?=E5=AF=BC=E8=87=B4=E9=87=8D=E8=AF=95=E7=9A=84=E9=94=99=E8=AF=AF?= =?UTF-8?q?=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/request/index.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/request/index.ts b/src/request/index.ts index 69bbdcf..c78e723 100644 --- a/src/request/index.ts +++ b/src/request/index.ts @@ -127,6 +127,9 @@ async function request(url: string | URL, _options: CommonRequestOpt } catch (e) { if (counter > maxRetry) { throw e; + } else { + console.log(`网络请求失败,进行第${counter}次重试,错误信息:`); + console.error(e); } } }