File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change 7878 DIR_MODE = 448 /* 0o700 */ ,
7979 FILE_MODE = 384 /* 0o600 */ ,
8080
81+ NODE_VERSION = process . versions . node . split ( '.' ) . map ( ( value ) => parseInt ( value , 10 ) ) ,
82+
8183 // this will hold the objects need to be removed on exit
8284 _removeObjects : CleanupCallback [ ] = [ ] ;
8385
@@ -522,11 +524,7 @@ function setGracefulCleanup(): void {
522524 _gracefulCleanup = true ;
523525}
524526
525- const version = process . versions . node . split ( '.' ) . map ( function ( value ) {
526- return parseInt ( value , 10 ) ;
527- } ) ;
528-
529- if ( version [ 0 ] === 0 && ( version [ 1 ] < 9 || version [ 1 ] === 9 && version [ 2 ] < 5 ) ) {
527+ if ( NODE_VERSION [ 0 ] === 0 && ( NODE_VERSION [ 1 ] < 9 || NODE_VERSION [ 1 ] === 9 && NODE_VERSION [ 2 ] < 5 ) ) {
530528 process . addListener ( 'uncaughtException' , function _uncaughtExceptionThrown ( err ) {
531529 _uncaughtException = true ;
532530 _garbageCollector ( ) ;
You can’t perform that action at this time.
0 commit comments