| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,6 +1,8 @@ | |||
| 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) } | |
| Back | FazBrowse Home | New Git URL |
0 commit comments