Shopify’s Mobile Buy SDK makes it simple to sell physical products inside your mobile app. With a few lines of code, you can connect your app with the Shopify platform and let your users buy your products using their credit card.
MIT License
214
stars
136
forks
source link
AbstractResponse hasErrors() should return true if any errors foudn #586
The hasErrors() method on AbstractResponse does not follow infer what a developer would think. This method makes it seem that it will return true if there are any errors in the query, however it only returns true if there are errors with retrieving the very top level of the query. hasErrors() should return true if any errors are found.
If a userError is found in the above method, hasErrors() will still return false, even though an error was in fact found.
If GraphQL is going to be used then we must at least escalate up some info to avoid these kind of issues
The hasErrors() method on AbstractResponse does not follow infer what a developer would think. This method makes it seem that it will return true if there are any errors in the query, however it only returns true if there are errors with retrieving the very top level of the query. hasErrors() should return true if any errors are found.
For example:
If a userError is found in the above method, hasErrors() will still return false, even though an error was in fact found. If GraphQL is going to be used then we must at least escalate up some info to avoid these kind of issues