From 3d4a3d5b2e59eb96d5e503f904a1924bc415c21a Mon Sep 17 00:00:00 2001 From: Ashary Vermaysha Date: Wed, 5 Jul 2023 09:47:39 +0700 Subject: [PATCH] fix: request return response --- src/request/request.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/request/request.ts b/src/request/request.ts index 9209e6c0..6f160c51 100644 --- a/src/request/request.ts +++ b/src/request/request.ts @@ -181,6 +181,8 @@ export class HTTPRequest { message: 'Too Many Request', }, headers: res.headers, + body: this.body, + params: this.params, }) } else if ( res.statusCode && @@ -301,7 +303,7 @@ export class HTTPRequest { /* c8 ignore start */ if ( - [-1004, -2016, -500_004, 429].includes(result.retcode) && + [-1004, -2016, -500_004, 429].includes(req.response.retcode) && this.retries <= 120 ) { this.retries++