Simplify protocol setup

pull/5302/head
Roman 2021-08-28 14:26:54 +01:00
parent f42fd0ecce
commit b269c2fdb9
1 changed files with 1 additions and 5 deletions

View File

@ -37,11 +37,7 @@ const env = envFromArgs(process.argv);
const profilePath = profileFromArgs(process.argv); const profilePath = profileFromArgs(process.argv);
const isDebugMode = !!process.argv && process.argv.indexOf('--debug') >= 0; const isDebugMode = !!process.argv && process.argv.indexOf('--debug') >= 0;
if (env === 'dev' && process.platform === 'win32') { electronApp.setAsDefaultProtocolClient('joplin');
electronApp.setAsDefaultProtocolClient('joplin', process.execPath, [process.argv[1]]);
} else {
electronApp.setAsDefaultProtocolClient('joplin');
}
const initialCallbackUrl = process.argv.find((arg) => isCallbackUrl(arg)); const initialCallbackUrl = process.argv.find((arg) => isCallbackUrl(arg));