Protect against unhandled promises when calling checkForUpdates
This commit is contained in:
parent
b3eb0646c0
commit
0ec0ae9dac
1 changed files with 7 additions and 3 deletions
|
@ -18,8 +18,12 @@ function autoUpdateDisabled() {
|
|||
);
|
||||
}
|
||||
|
||||
function checkForUpdates() {
|
||||
autoUpdater.checkForUpdates();
|
||||
async function checkForUpdates() {
|
||||
try {
|
||||
await autoUpdater.checkForUpdates();
|
||||
} catch (error) {
|
||||
console.log('checkForUpdates error:', error.stack);
|
||||
}
|
||||
}
|
||||
|
||||
let showingDialog = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue