Skip to content

Commit a66490b

Browse files
authored
fix(npm): small type fix to resolve ci (#12514)
1 parent ba98aa4 commit a66490b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

npm/src/bin.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ function forwardSignal(signal) {
143143
if (!child.killed)
144144
child.kill(signal)
145145
} catch (error) {
146-
if (!error || error.code !== 'ESRCH')
146+
if (!error || (typeof error === 'object' && 'code' in error && error.code !== 'ESRCH'))
147147
throw error
148148
}
149149

0 commit comments

Comments
 (0)