diff --git a/electron/index.js b/electron/index.js index 015b9f43b..76f50f821 100644 --- a/electron/index.js +++ b/electron/index.js @@ -45,13 +45,12 @@ let daemon; let lbryFirst; const appState = {}; - -const PROTOCOL = 'lbry' +const PROTOCOL = 'lbry'; if (isDev && process.platform === 'win32') { // Setting this is required to get this working in dev mode. app.setAsDefaultProtocolClient(PROTOCOL, process.execPath, [ - path.resolve(process.argv[1]) + path.resolve(process.argv[1]), ]); } else { app.setAsDefaultProtocolClient(PROTOCOL); @@ -157,11 +156,11 @@ if (!gotSingleInstanceLock) { // Send the url to the app to navigate first, then focus if (rendererWindow) { // External uri (last item on argv): - const EXTERNAL_URI = argv[argv.length ? (argv.length-1) : 0] + const EXTERNAL_URI = (argv.length) ? argv[argv.length - 1] : ''; // Handle protocol requests for windows and linux - const platforms = (process.platform === 'win32' || process.platform === 'linux') + const platforms = (process.platform === 'win32' || process.platform === 'linux'); // Is LBRY protocol - const isProtocolURI = String(EXTERNAL_URI).startsWith(PROTOCOL) + const isProtocolURI = String(EXTERNAL_URI).startsWith(PROTOCOL + '://'); // External protocol requested: if (platforms && isProtocolURI) { let URI = EXTERNAL_URI; @@ -210,7 +209,7 @@ if (!gotSingleInstanceLock) { if (details.method === 'POST' && details.requestHeaders['Content-Type'] === 'application/json-rpc') { delete details.requestHeaders['Origin']; } - callback({ cancel: false, requestHeaders: details.requestHeaders }); + callback({ cancel: false, requestHeaders: details.requestHeaders, }); }); }); } diff --git a/static/app-strings.json b/static/app-strings.json index f2011e06f..18cab4302 100644 --- a/static/app-strings.json +++ b/static/app-strings.json @@ -2064,12 +2064,10 @@ "Skip Navigation": "Skip Navigation", "Reset": "Reset", "Reset to original (previous) publish date": "Reset to original (previous) publish date", - "Show reply": "Show reply", - "Show %count% replies": "Show %count% replies", - "Open in Desktop": "Open in Desktop", "%title% by %channelTitle%": "%title% by %channelTitle%", "%title% by %channelTitle% %ariaDate%": "%title% by %channelTitle% %ariaDate%", "%title% by %channelTitle% %ariaDate%, %mediaDuration%": "%title% by %channelTitle% %ariaDate%, %mediaDuration%", "Search for something...": "Search for something...", + "Open in Desktop": "Open in Desktop", "--end--": "--end--" }