@@ -48,7 +48,7 @@ export function createOrUpdateFileNode(
4848 fileNode . typecheck = ! ! file . meta && 'typecheck' in file . meta
4949 fileNode . state = file . result ?. state
5050 fileNode . mode = file . mode
51- fileNode . duration = file . result ?. duration
51+ fileNode . duration = typeof file . result ?. duration === 'number' ? Math . round ( file . result . duration ) : undefined
5252 fileNode . collectDuration = file . collectDuration
5353 fileNode . setupDuration = file . setupDuration
5454 fileNode . environmentLoad = file . environmentLoad
@@ -68,7 +68,7 @@ export function createOrUpdateFileNode(
6868 tasks : [ ] ,
6969 typecheck : ! ! file . meta && 'typecheck' in file . meta ,
7070 indent : 0 ,
71- duration : file . result ?. duration != null ? Math . round ( file . result ? .duration ) : undefined ,
71+ duration : typeof file . result ?. duration === 'number' ? Math . round ( file . result . duration ) : undefined ,
7272 filepath : file . filepath ,
7373 projectName : file . projectName || '' ,
7474 projectNameColor : explorerTree . colors . get ( file . projectName || '' ) || getProjectNameColor ( file . projectName ) ,
@@ -131,8 +131,8 @@ export function createOrUpdateNode(
131131) {
132132 const node = explorerTree . nodes . get ( parentId ) as ParentTreeNode | undefined
133133 let taskNode : UITaskTreeNode | undefined
134- const duration = task . result ?. duration != null
135- ? Math . round ( task . result ? .duration )
134+ const duration = typeof task . result ?. duration === 'number'
135+ ? Math . round ( task . result . duration )
136136 : undefined
137137 if ( node ) {
138138 taskNode = explorerTree . nodes . get ( task . id )
0 commit comments