Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

Commit

Permalink
Merge pull request #19 from silktide/feature/override-host
Browse files Browse the repository at this point in the history
Update static create function
  • Loading branch information
B3none authored Aug 2, 2022
2 parents d1ec3f3 + b84f962 commit e5478ad
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ProspectClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ private function __construct(HttpWrapper $httpWrapper)
$this->httpWrapper = $httpWrapper;
}

public static function createFromApiKey(string $apiKey, ?string $locale = null)
public static function createFromApiKey(string $apiKey, ?string $locale = null, ?string $host = null): ProspectClient
{
return new ProspectClient(new HttpWrapper($apiKey, $locale));
return new ProspectClient(new HttpWrapper($apiKey, $locale, null, $host));
}

public static function createFromHttpWrapper(HttpWrapper $httpWrapper)
public static function createFromHttpWrapper(HttpWrapper $httpWrapper): ProspectClient
{
return new ProspectClient($httpWrapper);
}
Expand Down

0 comments on commit e5478ad

Please sign in to comment.