From d6f06333cfc3542199161828c8d8aab7e16f507a Mon Sep 17 00:00:00 2001 From: gggeek Date: Thu, 27 Jun 2024 08:35:19 +0000 Subject: [PATCH] set correct status_code in response on http exception --- src/Request.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Request.php b/src/Request.php index 8da377b0..bf76741a 100644 --- a/src/Request.php +++ b/src/Request.php @@ -247,7 +247,7 @@ class Request } catch (HttpException $e) { // failed processing of HTTP response headers // save into response obj the full payload received, for debugging - return new Response(0, $e->getCode(), $e->getMessage(), '', array('raw_data' => $data, 'status_code', $e->statusCode())); + return new Response(0, $e->getCode(), $e->getMessage(), '', array('raw_data' => $data, 'status_code' => $e->statusCode())); } catch(\Exception $e) { return new Response(0, $e->getCode(), $e->getMessage(), '', array('raw_data' => $data)); } -- 2.47.0