We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
I think it is better to add in the generated sample code a check (even if commented) for HTTP status code (just as a hint). example:
if resp.StatusCode != http.StatusOK { // handle status code not 200 }
BTW, I spent long time not sure what is the error until I realized at the end that, the status code check is not there 😄
The text was updated successfully, but these errors were encountered:
Maybe if resp.StatusCode >= 400 is more suitable. But yeah, that's a reasonable idea.
if resp.StatusCode >= 400
Sorry, something went wrong.
at end of the day, it is a hint for the developer that not to forget such checks
No branches or pull requests
I think it is better to add in the generated sample code a check (even if commented) for HTTP status code (just as a hint). example:
BTW, I spent long time not sure what is the error until I realized at the end that, the status code check is not there 😄
The text was updated successfully, but these errors were encountered: