From ebc69c5faf61a0b49656b59abf1082829f8bb5ae Mon Sep 17 00:00:00 2001 From: ethernet Date: Thu, 24 Sep 2026 06:30:30 -0400 Subject: [PATCH] style(desktop): keep PM source-check bridge lint clean --- apps/desktop/electron/updater/checkout-legacy.test.ts | 1 + apps/desktop/electron/updater/checkout-source.ts | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/apps/desktop/electron/updater/checkout-legacy.test.ts b/apps/desktop/electron/updater/checkout-legacy.test.ts index 403ad3bc21..1dec0fbb4b 100644 --- a/apps/desktop/electron/updater/checkout-legacy.test.ts +++ b/apps/desktop/electron/updater/checkout-legacy.test.ts @@ -115,6 +115,7 @@ it.skipIf(process.platform !== 'win32')( hermesHome: home, channel: 'stable' as const } + await expect(readSourceUpdate(probe)).resolves.toMatchObject({ supported: true, channel: 'stable', behind: null }) await expect(readSourceUpdate({ ...probe, branch: 'main&echo INJECTED' })).rejects.toThrow( 'unsafe Windows command argument' diff --git a/apps/desktop/electron/updater/checkout-source.ts b/apps/desktop/electron/updater/checkout-source.ts index 0a0171cbdf..f571444160 100644 --- a/apps/desktop/electron/updater/checkout-source.ts +++ b/apps/desktop/electron/updater/checkout-source.ts @@ -46,6 +46,7 @@ export async function readSourceUpdate(probe: SourceUpdateProbe): Promise /["%&|<>^\r\n]/.test(value))) { throw new Error('The source check contains an unsafe Windows command argument.') } + const result: { stdout: string; stderr: string } = await execute( viaCmd ? (process.env.ComSpec ?? 'cmd.exe') : command, viaCmd