Skip to content

Commit 5797d31

Browse files
Merge branch '5.3' into 5.4
* 5.3: [HttpClient] Remove deprecated usage of `GuzzleHttp\Promise\queue` [PropertyAccess] Fix handling of uninitialized property of anonymous class [FrameworkBundle] Allow default cache pools to be overwritten by user [DependencyInjection] fix test ResolveBindingsPass remove loading of class iterable [FrameworkBundle] Avoid calling rtrim(null, '/') in AssetsInstallCommand [DependencyInjection] Fix nested env var with resolve processor Allow OutputFormatter::escape() to be used for escaping URLs used in <href> allow a zero time-limit [DependencyInjection] Ignore argument type check in CheckTypeDeclarationsPass if it's a Definition with a factory [Validators] Add translations for Slovak #43735
2 parents de370b6 + 6a4ab5f commit 5797d31

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

HttplugClient.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313

1414
use GuzzleHttp\Promise\Promise as GuzzlePromise;
1515
use GuzzleHttp\Promise\RejectedPromise;
16+
use GuzzleHttp\Promise\Utils;
1617
use Http\Client\Exception\NetworkException;
1718
use Http\Client\Exception\RequestException;
1819
use Http\Client\HttpAsyncClient;
@@ -75,7 +76,7 @@ public function __construct(HttpClientInterface $client = null, ResponseFactoryI
7576
$this->client = $client ?? HttpClient::create();
7677
$this->responseFactory = $responseFactory;
7778
$this->streamFactory = $streamFactory ?? ($responseFactory instanceof StreamFactoryInterface ? $responseFactory : null);
78-
$this->promisePool = \function_exists('GuzzleHttp\Promise\queue') ? new \SplObjectStorage() : null;
79+
$this->promisePool = class_exists(Utils::class) ? new \SplObjectStorage() : null;
7980

8081
if (null === $this->responseFactory || null === $this->streamFactory) {
8182
if (!class_exists(Psr17Factory::class) && !class_exists(Psr17FactoryDiscovery::class)) {

Internal/HttplugWaitLoop.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public function wait(?ResponseInterface $pendingResponse, float $maxDuration = n
5252
return 0;
5353
}
5454

55-
$guzzleQueue = \GuzzleHttp\Promise\queue();
55+
$guzzleQueue = \GuzzleHttp\Promise\Utils::queue();
5656

5757
if (0.0 === $remainingDuration = $maxDuration) {
5858
$idleTimeout = 0.0;

0 commit comments

Comments
 (0)