diff options
author | Florrie <towerofnix@gmail.com> | 2020-07-10 11:25:59 -0300 |
---|---|---|
committer | Florrie <towerofnix@gmail.com> | 2020-07-10 11:30:13 -0300 |
commit | 8927fb3f3ef9a3d641cf607a756b8815f06c57e2 (patch) | |
tree | d40fbcacd6ab21e9ea9204d7cb0457758ad7fb97 | |
parent | 7ea3291db7dd2de13e9f07005e83524711f086af (diff) |
update old process.argv checks to use parseOptions
-rwxr-xr-x | index.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/index.js b/index.js index f0cd4e3..444d579 100755 --- a/index.js +++ b/index.js @@ -65,9 +65,9 @@ async function main() { } } }, - 'player-options': { - type: 'series' - }, + 'player-options': {type: 'series'}, + 'stress-test': {type: 'flag'}, + 'telnet-server': {type: 'flag'}, [parseOptions.handleDashless](option) { playlistSources.push(option) } @@ -132,13 +132,13 @@ async function main() { const loadPlaylistPromise = loadPlaylists() let telnetServer - if (process.argv.includes('--telnet-server')) { + if (options['telnet-server']) { telnetServer = new TelnetServer(backend) await telnetServer.listen(1244) appElement.attachAsServerHost(telnetServer) } - if (process.argv.includes('--stress-test')) { + if (options['stress-test']) { await loadPlaylistPromise const w = 80 |