Skip to content

fix: refactor for DRY principles. - #48

Merged
sadsfae merged 1 commit into
developmentfrom
dry_refactor
Jul 15, 2026
Merged

fix: refactor for DRY principles.#48
sadsfae merged 1 commit into
developmentfrom
dry_refactor

Conversation

@sadsfae

@sadsfae sadsfae commented Jul 15, 2026

Copy link
Copy Markdown
Owner

Source code (cli.py):

  • Replaced 10-line _get_version() file parser with from mozzo import version
  • Removed redundant timeout=60 kwarg
  • Moved "cmd_mod": 2 injection into _post_cmd(), removed from 6 callers
  • Extracted _fetch_alerting_services() helper, replacing identical 5-line blocks in 2 methods
  • Added ISSUE_STATUS_CODES = {4, 8, 16} class constant

  Source code (cli.py):
  - C1: Replaced 10-line _get_version() file parser with from mozzo import __version__
  - C5: Removed redundant timeout=60 kwarg
  - S12: Moved "cmd_mod": 2 injection into _post_cmd(), removed from 6 callers
  - S1: Extracted _fetch_alerting_services() helper, replacing identical 5-line blocks in 2 methods
  - S2: Added ISSUE_STATUS_CODES = {4, 8, 16} class constant, updated 2 of 3 references (line 631 kept as-is per plan)
@sadsfae
sadsfae merged commit 7a598b6 into development Jul 15, 2026
5 checks passed
@sadsfae
sadsfae deleted the dry_refactor branch July 15, 2026 07:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant