1
0
mirror of https://github.com/mifi/lossless-cut.git synced 2024-11-25 11:43:17 +01:00

fix error when opening LC first time on mac

This commit is contained in:
Mikael Finstad 2020-02-11 22:16:19 +08:00
parent 7ca8524f12
commit 72145c46fc

View File

@ -63,6 +63,7 @@ app.on('activate', () => {
electron.ipcMain.on('renderer-ready', () => {
if (!isDev) {
const fileToOpen = process.argv[1];
if (fileToOpen) mainWindow.webContents.send('file-opened', [fileToOpen]);
// https://github.com/electron/electron/issues/3657
if (fileToOpen && !fileToOpen.startsWith('-psn_')) mainWindow.webContents.send('file-opened', [fileToOpen]);
}
});