Closed jamesmbaazam closed 7 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
00d337d
) 98.90% compared to head (9881e08
) 98.90%.:exclamation: Current head 9881e08 differs from pull request most recent head 06ced1b. Consider uploading reports for the commit 06ced1b to get more accurate results
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
[x] I have read the CONTRIBUTING guidelines
[x] The commit message follows our guidelines
[x] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
A failsafe to prevent bugs.
The helper functions
.update_chain_stat()
and.get_statistic_func()
usedswitch()
statements that did not error if there was no match. In fact,switch()
statements return NULL if there is no match, which could potentially cause bugs downstream. However, the current state of the code is fine because in the function that it is called, the argument passed to it is matched at the top, and errors there.The functions will now error when there is no match instead of returning
NULL
, which could cause bugs.No.
Other information:
This PR closes #200.
This change is probably unnecessary because the arguments passed to these helpers are checked and would error before being passed down to this function.