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

improving error handling in a more go way #9

Merged
merged 5 commits into from
Oct 12, 2020
Merged

improving error handling in a more go way #9

merged 5 commits into from
Oct 12, 2020

Conversation

finfinack
Copy link
Contributor

Offering some code cleanup, in particular:

  • improving readability by reducing indentation
  • improving error handling in a more go way

clean up some of the error handling: more complex defers are not needed when a potentially returned error is not handled anyway.
reduce complexity of ProcessMessages function. Removing indentation by returning early where possible.
some error refactoring and readability improvements (less indentation) and switch statements where they offer an improvement over ifs.
@haroon-sheikh
Copy link
Collaborator

Thank you @finfinack for your contribution.

@haroon-sheikh haroon-sheikh changed the title Code cleanup improving error handling in a more go way Oct 12, 2020
@haroon-sheikh haroon-sheikh merged commit 08db370 into sitture:master Oct 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants