Closed yjukaku closed 5 years ago
👋 I made the changes as requested - any chance of this getting merged and released soon? 😁
Thanks for contributing @yjukaku! This LGTM after your changes. 👍
@prsimp Any further concerns?
❤️ Awesome, thanks all! Looking forward to the release. 🚀
This closes #50 by asking the HTTP library to explicitly parse the response as JSON. If that fails, we get a specific error type,
JSON::ParserError
. We then turn that into aTaxjar::Error::ServerError
.In some cases, the TaxJar API is returning HTML with the
Content-Type text/html
and that causes this library to fail with a generic error from the http-ruby library. With this change, we will have a specific error that is namespaced byTaxjar
.