Closed Nyholm closed 8 years ago
Why?
Because the diacovery is a lightweight package, we do not have to do checks if the discovery exists or not. It may also make the installation/download/bootstrap a bit easier.
And also, like I said above. All other clients and adapters have a hard dependency or no dependency.
Since in fact there is no actual dependency on discovery, I think it would be better to remove checks from the code.
Removing these: https://github.com/php-http/curl-client/blob/master/src/Client.php#L85-L90
Will make the constructor arguments non-optional.
I suggest doing as the Guzzle5 adapter does: https://github.com/php-http/guzzle5-adapter/blob/master/src/Client.php#L40
OK.
You are quick. Thank you!
Like we did in our other clients and adapters.
What do you think?