thephpleague / oauth2-github

GitHub Provider for the OAuth 2.0 Client
MIT License
106 stars 29 forks source link

Fix #4: Check if Github's response contains an error #5

Closed nesk closed 8 years ago

nesk commented 8 years ago

Btw, just noticed you try to get a string from the message property, bug Github describes an error_description property. Should I fix this? Because of this, I didn't write any tests for my use case since it would have been messy managing the message and error_description properties in the same test.

stevenmaguire commented 8 years ago

Thanks for the PR. The build is failing because the code in the PR does not meet the coding style standards. Please fix them and push the updated changes to your branch.

https://travis-ci.org/thephpleague/oauth2-github/jobs/102925788#L199

The message property is appropriate for client errors that are handled in the Gihub API, so the existing code is just fine for that case. The error_description property appears to be relevant to the OAuth specific responses, like the case you are building towards.

Please ensure you provide enough test coverage to keep this project at 100% code coverage.

stevenmaguire commented 8 years ago

@nesk this PR is still open and has errors. Should we close or would you like to resolve the errors?

nesk commented 8 years ago

@stevenmaguire Sorry, I didn't take time to work on this and I went with another solution. I'm closing this PR since I'm not sure I will work again on it.