Merge pull request #789 from feross/ignore-dot
Ignore '.' argument which is annoying in development
This commit is contained in:
@@ -34,8 +34,8 @@ if (process.platform === 'win32') {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!shouldQuit) {
|
if (!shouldQuit) {
|
||||||
// Prevent multiple instances of app from running at same time. New instances signal
|
// Prevent multiple instances of app from running at same time. New instances
|
||||||
// this instance and quit.
|
// signal this instance and quit.
|
||||||
shouldQuit = app.makeSingleInstance(onAppOpen)
|
shouldQuit = app.makeSingleInstance(onAppOpen)
|
||||||
if (shouldQuit) {
|
if (shouldQuit) {
|
||||||
app.quit()
|
app.quit()
|
||||||
@@ -159,7 +159,10 @@ function processArgv (argv) {
|
|||||||
} else if (arg.startsWith('-psn')) {
|
} else if (arg.startsWith('-psn')) {
|
||||||
// Ignore Mac launchd "process serial number" argument
|
// Ignore Mac launchd "process serial number" argument
|
||||||
// Issue: https://github.com/feross/webtorrent-desktop/issues/214
|
// Issue: https://github.com/feross/webtorrent-desktop/issues/214
|
||||||
} else {
|
} else if (arg !== '.') {
|
||||||
|
// Ignore '.' argument, which gets misinterpreted as a torrent id, when a
|
||||||
|
// development copy of WebTorrent is started while a production version is
|
||||||
|
// running.
|
||||||
torrentIds.push(arg)
|
torrentIds.push(arg)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user