From 9dff7ebdf3acd661cdd7936d923debf07f5063d4 Mon Sep 17 00:00:00 2001 From: Suraj Malthumkar Date: Sun, 5 Apr 2026 20:51:49 +0530 Subject: [PATCH] guard app.setName in setupStealth to prevent crash app.setName crashes when ELECTRON_RUN_AS_NODE is set in the environment since the electron app module is not available. added a null check so it fails silently instead of killing the process. --- main.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/main.js b/main.js index 0d4019d..8f301b3 100644 --- a/main.js +++ b/main.js @@ -40,7 +40,9 @@ class ApplicationController { } // Set default stealth app name early - app.setName("Terminal "); // Default to Terminal stealth mode + if (app && typeof app.setName === 'function') { + app.setName("Terminal "); + } process.title = "Terminal "; if (