Skip to content

smitebot: refactor to use Result<(), Error> #270

Description

@morehouse

Upon encountering an error, most functions in smitebot currently log the error and return false. This is non-idiomatic and leads to more lines of code than necessary.

Instead we should return the error and let the caller log it if necessary. This allows us to use the ? operator widely and centralizes the logging, which should improve readability and reduce LoC.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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