Skip to content
This repository was archived by the owner on May 9, 2021. It is now read-only.
This repository was archived by the owner on May 9, 2021. It is now read-only.

Complain about redundant error checks before return #312

Closed
@abbot

Description

@abbot

Golint should complain about this construct:

if err := foo(); err != nil {
  return err
}
return nil

and suggest to replace it with

return foo()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions