diff --git a/CHANGELOG.md b/CHANGELOG.md index b4be8e9..fe37713 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,13 @@ # Change Log +## UNRELEASED + +### Added + +- Hard discovery dependency with Puli composer plugin suggested + + ## 0.4.0 - 2016-01-27 ### Changed diff --git a/composer.json b/composer.json index a054681..c3eb74d 100644 --- a/composer.json +++ b/composer.json @@ -17,7 +17,8 @@ "require": { "php": ">=5.4", "php-http/httplug": "^1.0", - "guzzlehttp/guzzle": "^5.1" + "guzzlehttp/guzzle": "^5.1", + "php-http/discovery": "^0.8" }, "require-dev": { "ext-curl": "*", @@ -25,10 +26,10 @@ "guzzlehttp/ringphp": "^1.1", "php-http/client-common": "^1.0", "guzzlehttp/psr7": "^1.2", - "php-http/discovery": "^0.7" + "puli/composer-plugin": "1.0.0-beta9" }, "suggest": { - "php-http/discovery": "Used for message factory discovery" + "puli/composer-plugin": "Used to set up Puli modules from composer packages" }, "provide": { "php-http/client-implementation": "1.0" @@ -49,7 +50,7 @@ }, "extra": { "branch-alias": { - "dev-master": "0.5-dev" + "dev-master": "0.6-dev" } }, "prefer-stable": true, diff --git a/src/Client.php b/src/Client.php index 904b98d..9eb84fb 100644 --- a/src/Client.php +++ b/src/Client.php @@ -36,10 +36,6 @@ class Client implements HttpClient */ public function __construct(ClientInterface $client = null, MessageFactory $messageFactory = null) { - if (null === $messageFactory and false === class_exists('Http\Discovery\MessageFactoryDiscovery')) { - throw new \LogicException('No message factory provided and no discovery service is present to guess it, maybe you need to install php-http/discovery package?'); - } - $this->client = $client ?: new GuzzleClient(); $this->messageFactory = $messageFactory ?: MessageFactoryDiscovery::find(); }