guzzle/guzzle — pull request #356 by Danack (2013-06-23 18:01:41+00:00)
Title: Only set optional Oauth params if they're set in config.

Don't add oauth_callback or oauth_verifier from the oauth config array to paramsToSign unless they are set. This prevents them being duplicated if they are set as parameters for a function in a service description.

The reason for doing this is that for me at least it's nicer to have the oauth_callback and oauth_verifier as part of the service description, so for any call that requires those parameters, a Guzzle\Service\Exception\ValidationException is thrown before the API call, rather than just getting a generic error code from the server.

However having these parameters listed as part of the service rather than the oauth config means that they are added twice, once with null and once with the real values. The request is then submitted with both of them stored in an array, which makes the request invalid.

cheers
Dan