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

make formatMsInterval tighter and add tests #3669

Merged
merged 2 commits into from
Dec 8, 2023

Conversation

bcolloran
Copy link
Contributor

This should fix #3655 -- this code is now as systematic as I know how to be in JS. Literally every everything value used in the function is either a literal of a defined type, a predefined constant field access, or a number, and any non-numeric input should be handle as well.

I was not able to reproduce the actual bug locally, so I can't 100% confirm that this will fix it, but it is now impossible to access the unit field on a possibly undefined value, because there is no more accessing of fields with runtime values.

Copy link
Contributor

@ericpgreen2 ericpgreen2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice. We can merge this, then test the triggering dashboard on the staging environment to confirm.

@ericpgreen2 ericpgreen2 merged commit 8e89646 into main Dec 8, 2023
2 checks passed
@ericpgreen2 ericpgreen2 deleted the tighten-formatMsInterval-and-add-tests branch December 8, 2023 21:54
mindspank pushed a commit that referenced this pull request Dec 18, 2023
* make formatMsInterval tighter and add tests

* cleanup
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.

Fix bug in formatMsInterval function
2 participants