Skip to content

Commit c5f8cb4

Browse files
Updated formatDuration to properly handle the lack of optional arguments
1 parent 00c5c56 commit c5f8cb4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/utils/tasks.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ export function jobMessageOutputs (jobNode) {
9898
* 00:00:00, rather than undefined
9999
* @return {string=} Formatted duration
100100
*/
101-
export function formatDuration (value, allowZeros = false, timingOption = false) {
101+
export function formatDuration (value, allowZeros = false, timingOption = true) {
102102
// Times are formatted as HH:MM:SS
103-
if (timingOption === 'queue' || timingOption === 'total' || timingOption === 'run' || timingOption === 'cpuTime') {
103+
if (timingOption === 'queue' || timingOption === 'total' || timingOption === 'run' || timingOption === 'cpuTime' || timingOption === true) {
104104
if (value || (value === 0 && allowZeros === true)) {
105105
// Convert CPU time to seconds
106106
if (timingOption === 'cpuTime') {

0 commit comments

Comments
 (0)