Skip to content

Commit

Permalink
FIX Respect strict-typing of Factory interface (#108)
Browse files Browse the repository at this point in the history
  • Loading branch information
GuySartorelli authored Jul 12, 2024
1 parent 2598d60 commit 773a73e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Services/ClientFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand All @@ -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));
}
Expand Down

0 comments on commit 773a73e

Please sign in to comment.