File tree 1 file changed +8
-5
lines changed
1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change 1
1
'use strict' ;
2
2
3
3
const {
4
+ ArrayPrototypePush,
5
+ ArrayPrototypeSlice,
4
6
JSONStringify,
5
7
} = primordials ;
6
8
@@ -22,17 +24,18 @@ const scriptFiles = [
22
24
] ;
23
25
let script = '' ;
24
26
25
- scriptFiles . forEach ( ( s ) => {
27
+ for ( const s of scriptFiles ) {
26
28
script += internalBinding ( 'natives' ) [ s ] + '\n' ;
27
- } ) ;
29
+ }
28
30
29
31
const tickArguments = [ ] ;
30
32
if ( process . platform === 'darwin' ) {
31
- tickArguments . push ( '--mac' ) ;
33
+ ArrayPrototypePush ( tickArguments , '--mac' ) ;
32
34
} else if ( process . platform === 'win32' ) {
33
- tickArguments . push ( '--windows' ) ;
35
+ ArrayPrototypePush ( tickArguments , '--windows' ) ;
34
36
}
35
- tickArguments . push . apply ( tickArguments , process . argv . slice ( 1 ) ) ;
37
+ ArrayPrototypePush ( tickArguments ,
38
+ ...ArrayPrototypeSlice ( process . argv , 1 ) ) ;
36
39
script = `(function(module, require) {
37
40
arguments = ${ JSONStringify ( tickArguments ) } ;
38
41
function write (s) { process.stdout.write(s) }
You can’t perform that action at this time.
0 commit comments