mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-12 20:18:41 -09:00
Do not register app for ssh:// url scheme handling on dev mode (#2745)
Fixes #2740
This commit is contained in:
parent
36cde0f23e
commit
4a127ef83b
1 changed files with 11 additions and 9 deletions
20
app/index.js
20
app/index.js
|
|
@ -183,15 +183,17 @@ app.on('ready', () =>
|
||||||
// expose to plugins
|
// expose to plugins
|
||||||
app.createWindow = createWindow;
|
app.createWindow = createWindow;
|
||||||
|
|
||||||
// check if should be set/removed as default ssh protocol client
|
if (!isDev) {
|
||||||
if (config.getConfig().defaultSSHApp && !app.isDefaultProtocolClient('ssh')) {
|
// check if should be set/removed as default ssh protocol client
|
||||||
//eslint-disable-next-line no-console
|
if (config.getConfig().defaultSSHApp && !app.isDefaultProtocolClient('ssh')) {
|
||||||
console.log('Setting Hyper as default client for ssh:// protocol');
|
//eslint-disable-next-line no-console
|
||||||
app.setAsDefaultProtocolClient('ssh');
|
console.log('Setting Hyper as default client for ssh:// protocol');
|
||||||
} else if (!config.getConfig().defaultSSHApp && app.isDefaultProtocolClient('ssh')) {
|
app.setAsDefaultProtocolClient('ssh');
|
||||||
//eslint-disable-next-line no-console
|
} else if (!config.getConfig().defaultSSHApp && app.isDefaultProtocolClient('ssh')) {
|
||||||
console.log('Removing Hyper from default client for ssh:// protocl');
|
//eslint-disable-next-line no-console
|
||||||
app.removeAsDefaultProtocolClient('ssh');
|
console.log('Removing Hyper from default client for ssh:// protocl');
|
||||||
|
app.removeAsDefaultProtocolClient('ssh');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// mac only. when the dock icon is clicked
|
// mac only. when the dock icon is clicked
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue