From ca7aa4031e57982ec7cd1f801059e3a29ef5b340 Mon Sep 17 00:00:00 2001 From: Matthias Vogel Date: Fri, 26 Aug 2022 13:26:31 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix=20rejected=20Guzzle=20Reject?= =?UTF-8?q?edPromise=20error?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Classes/Utility/GuzzleUtility.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Classes/Utility/GuzzleUtility.php b/Classes/Utility/GuzzleUtility.php index 6e7c0d3..042daaa 100644 --- a/Classes/Utility/GuzzleUtility.php +++ b/Classes/Utility/GuzzleUtility.php @@ -5,7 +5,7 @@ namespace Kanti\ServerTiming\Utility; use Closure; -use GuzzleHttp\Promise\FulfilledPromise; +use GuzzleHttp\Promise\PromiseInterface; use Psr\Http\Message\RequestInterface; class GuzzleUtility @@ -13,7 +13,7 @@ class GuzzleUtility public static function getHandler(): Closure { return static function (callable $handler): Closure { - return static function (RequestInterface $request, array $options) use ($handler): FulfilledPromise { + return static function (RequestInterface $request, array $options) use ($handler): PromiseInterface { $info = $request->getMethod() . ' ' . $request->getUri()->__toString(); $stop = TimingUtility::stopWatch('guzzle', $info); $response = $handler($request, $options);