2
2
mirror of https://github.com/Llewellynvdm/nativefier.git synced 2024-11-11 07:41:04 +00:00

Fix app not starting since widevine PR / #1164 (#1170)

This commit is contained in:
Ronan Jouchet 2021-04-30 01:23:13 -04:00 committed by GitHub
parent ec0ea4bd67
commit c4356e48f1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -190,22 +190,25 @@ if (shouldQuit) {
} }
}); });
if (appArgs.widevine !== undefined) { if (appArgs.widevine) {
// @ts-ignore This event only appear on the widevine version of electron, which we'd see at runtime // @ts-ignore This event only appears on the widevine version of electron, which we'd see at runtime
app.on('widevine-ready', (version, lastVersion) => { app.on('widevine-ready', (version: string, lastVersion: string) => {
console.log('widevine-ready', version, lastVersion); console.log('widevine-ready', version, lastVersion);
onReady(); onReady();
}); });
// @ts-ignore This event only appear on the widevine version of electron, which we'd see at runtime app.on(
app.on('widevine-update-pending', (currentVersion, pendingVersion) => { // @ts-ignore This event only appears on the widevine version of electron, which we'd see at runtime
console.log( 'widevine-update-pending',
`Widevine ${currentVersion} is ready to be upgraded to ${pendingVersion}`, (currentVersion: string, pendingVersion: string) => {
); console.log(
}); `Widevine ${currentVersion} is ready to be upgraded to ${pendingVersion}`,
);
},
);
// @ts-ignore This event only appear on the widevine version of electron, which we'd see at runtime // @ts-ignore This event only appears on the widevine version of electron, which we'd see at runtime
app.on('widevine-error', (error) => { app.on('widevine-error', (error: any) => {
console.error('WIDEVINE ERROR: ', error); console.error('WIDEVINE ERROR: ', error);
}); });
} else { } else {