This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class DateMeasure { | |
constructor(ms) { | |
const negativeMS = ms < 0; | |
let d, h, m, s; | |
// this change is needed for it to work with | |
// date1 before date2 diffs | |
if (negativeMS) { | |
ms *= -1; | |
} |