Break timeHelpers into smaller functions
Code from @nickstenning, introduce the breakpoints array and search in it for the needed fuzzystring and when to update next instead of a complex else-if tree. timeHelpers service has two functions: - toFuzzyString: returns the fuzzy time string - nextFuzzyUpdate: returns the next time to update (in sec)
Showing
Please register or sign in to comment