diff --git a/CHANGELOG.md b/CHANGELOG.md index 479b7c9e..f9ca9cab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## Unreleased +- [#465](https://github.com/Shopify/shopify-api-php/pull/465) [Patch] Cast `Content-Length` header value to `string` in `Http::request()` to avoid a `guzzlehttp/psr7` 2.11 deprecation (`Passing int to MessageInterface::withHeader() is deprecated`) and stay compatible with `guzzlehttp/psr7` 3.0 ## v6.1.1 - 2026-03-02 - [#456](https://github.com/Shopify/shopify-api-php/pull/456) [Patch] Update firebase/php-jwt to ^7.0 to address security vulnerability (GHSA-2x45-7fc3-mxwq) diff --git a/src/Clients/Http.php b/src/Clients/Http.php index 4f03ab61..292661f1 100644 --- a/src/Clients/Http.php +++ b/src/Clients/Http.php @@ -207,7 +207,7 @@ protected function request( $request = $request ->withBody($stream) ->withHeader(HttpHeaders::CONTENT_TYPE, $dataType) - ->withHeader(HttpHeaders::CONTENT_LENGTH, mb_strlen($bodyString)); + ->withHeader(HttpHeaders::CONTENT_LENGTH, (string) mb_strlen($bodyString)); } $currentTries = 0;