()
| 129 | }; |
| 130 | |
| 131 | const ensureSingleInstance = () => { |
| 132 | if (!app.requestSingleInstanceLock()) { |
| 133 | app.quit(); |
| 134 | return false; |
| 135 | } |
| 136 | app.on("second-instance", focusMainWindow); |
| 137 | return true; |
| 138 | }; |
| 139 | |
| 140 | /** |
| 141 | * Stop the local server only when WE own it. A supervised daemon (launchd/etc.) |