From 1d4d366e47153886ad8c1fe559140cd888ed4a6b Mon Sep 17 00:00:00 2001 From: Guy Sartorelli Date: Tue, 9 Jul 2024 10:15:51 +1200 Subject: [PATCH] FIX Respect strict-typing of Factory interface --- src/Services/ClientFactory.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Services/ClientFactory.php b/src/Services/ClientFactory.php index ef066f0..ec2693d 100644 --- a/src/Services/ClientFactory.php +++ b/src/Services/ClientFactory.php @@ -2,6 +2,7 @@ namespace SilverStripe\EnvironmentCheck\Services; +use Psr\Http\Client\ClientInterface; use GuzzleHttp\Client as GuzzleClient; use SilverStripe\Core\Injector\Factory; use SilverStripe\Core\Config\Configurable; @@ -28,7 +29,7 @@ class ClientFactory implements Factory * * {@inheritdoc} */ - public function create($service, array $params = []) + public function create(string $service, array $params = []): ClientInterface { return new GuzzleClient($this->getConfig($params)); }