mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-14 04:48:40 -09:00
fix breaking change in shell.openItem
https://github.com/electron/electron/pull/20682
This commit is contained in:
parent
2a78d13e93
commit
a1b92dea3f
1 changed files with 2 additions and 2 deletions
|
|
@ -71,7 +71,7 @@ export default () => {
|
|||
return hasDefaultSet()
|
||||
.then((yes) => {
|
||||
if (yes) {
|
||||
return shell.openItem(cfgPath);
|
||||
return shell.openPath(cfgPath).then((error) => error === '');
|
||||
}
|
||||
console.warn('No default app set for .js files, using notepad.exe fallback');
|
||||
return openNotepad(cfgPath);
|
||||
|
|
@ -81,6 +81,6 @@ export default () => {
|
|||
return openNotepad(cfgPath);
|
||||
});
|
||||
} else {
|
||||
return Promise.resolve(shell.openItem(cfgPath));
|
||||
return Promise.resolve(shell.openPath(cfgPath).then((error) => error === ''));
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue