Skip to content

Commit 969332c

Browse files
committed
Fixed single instance behaviour
1 parent d9c8e04 commit 969332c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/ElectronNET.API/Runtime/StartupManager.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,11 +167,11 @@ private BuildInfo GatherBuildInfo()
167167

168168
if (isSingleInstance?.Length > 0 && bool.TryParse(isSingleInstance, out var isSingleInstanceActive) && isSingleInstanceActive)
169169
{
170-
buildInfo.ElectronSingleInstance = "yes";
170+
buildInfo.ElectronSingleInstance = "True";
171171
}
172172
else
173173
{
174-
buildInfo.ElectronSingleInstance = "no";
174+
buildInfo.ElectronSingleInstance = "False";
175175
}
176176

177177
if (httpPort?.Length > 0 && int.TryParse(httpPort, out var port))

src/ElectronNET.Host/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ app.on('will-finish-launching', () => {
9393

9494
const manifestJsonFile = require(manifestJsonFilePath);
9595

96-
if (manifestJsonFile.singleInstance === "yes") {
96+
if (manifestJsonFile.singleInstance === "True") {
9797
const mainInstance = app.requestSingleInstanceLock();
9898
app.on('second-instance', (events, args = []) => {
9999
args.forEach((parameter) => {

0 commit comments

Comments
 (0)