Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More issues caught by linter #79

Open
wants to merge 17 commits into
base: main
Choose a base branch
from
Open

More issues caught by linter #79

wants to merge 17 commits into from

Commits on Jun 14, 2022

  1. Fix S1009 issue discovered by linter

    nil slices have a length of zero, remove the redundant check
    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    03fafa8 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cda6823 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    238fb11 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    9ade3e6 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    8c54394 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    61550bb View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    b719312 View commit details
    Browse the repository at this point in the history
  8. Outdent else block

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    69a16bd View commit details
    Browse the repository at this point in the history
  9. Explicitly close response body

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    69d5b93 View commit details
    Browse the repository at this point in the history
  10. Preallocate children slice

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    3ad32bc View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    f33710b View commit details
    Browse the repository at this point in the history
  12. Fold else...if into else if

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    24ef857 View commit details
    Browse the repository at this point in the history
  13. Remove unnecessary conversion

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    8f51c2c View commit details
    Browse the repository at this point in the history
  14. Remove unnecessary slices

    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    cdc52cb View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    9bc60af View commit details
    Browse the repository at this point in the history
  16. Use %w instead of %v for errors

    This allows callers to unwrap errors with errors.Is() and errors.As()
    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    ff2bffa View commit details
    Browse the repository at this point in the history
  17. Replace archaic error comparison with errors.Is

    This will futureproof us if they ever suddenly change how CheckDecode
    wraps errors
    qua3k committed Jun 14, 2022
    Configuration menu
    Copy the full SHA
    1bd773d View commit details
    Browse the repository at this point in the history