Fix io.element.desktop protocol handler (#2280) (#2281)

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
ElementRobot
2025-04-23 12:49:47 +02:00
committed by GitHub
parent 906b5bc93c
commit 216b1c2157

View File

@@ -117,7 +117,7 @@ export function protocolInit(): void {
// Protocol handler for win32/Linux
app.on("second-instance", (ev, commandLine) => {
const url = commandLine[commandLine.length - 1];
if (!url.startsWith(`${PROTOCOL}://`) && !url.startsWith(`${LEGACY_PROTOCOL}://`)) return;
if (!url.startsWith(`${PROTOCOL}:/`) && !url.startsWith(`${LEGACY_PROTOCOL}://`)) return;
processUrl(url);
});
}