diff --git a/package-lock.json b/package-lock.json index f0c51fa..4e45214 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "folio", - "version": "0.1.14", + "version": "0.1.15", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "folio", - "version": "0.1.14", + "version": "0.1.15", "license": "MIT", "dependencies": { "@tiptap/core": "^2.27.2", diff --git a/package.json b/package.json index 099acf8..85cbb3f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "folio", - "version": "0.1.14", + "version": "0.1.15", "description": "A simple, local, open-source desktop writing app.", "productName": "Folio", "author": "Folio Contributors", diff --git a/src/main/index.ts b/src/main/index.ts index e666950..3596ddb 100644 --- a/src/main/index.ts +++ b/src/main/index.ts @@ -1423,4 +1423,8 @@ if (app.requestSingleInstanceLock()) { } if (f) openFromArg(f); }); +} else { + // Lost the lock: another Folio is already running. Without this quit the + // second process falls through to whenReady() and opens a duplicate window. + app.quit(); }