From 87ec8fca93cb4373392bd05a946150557f5cb596 Mon Sep 17 00:00:00 2001 From: webadderall <131426131+webadderall@users.noreply.github.com> Date: Fri, 17 Apr 2026 20:56:50 +1000 Subject: [PATCH] fix: revert overly strict isAllowedLocalReadPath to OR logic The AND gate broke access to user-selected files outside the allowlist (wallpapers, user videos, etc). Keep isPathInsideDirectory normalization fix, revert the existsSync AND guard back to the original OR behavior. --- electron/ipc/project/manager.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/electron/ipc/project/manager.ts b/electron/ipc/project/manager.ts index 2db9e774..faabccfe 100644 --- a/electron/ipc/project/manager.ts +++ b/electron/ipc/project/manager.ts @@ -53,9 +53,9 @@ export function isAllowedLocalReadPath(candidatePath: string) { const allowedPrefixes = [RECORDINGS_DIR, USER_DATA_PATH, getAssetRootPath(), app.getPath("temp")]; return ( - existsSync(candidatePath) && - (allowedPrefixes.some((prefix) => isPathInsideDirectory(candidatePath, prefix)) || - approvedLocalReadPaths.has(candidatePath)) + existsSync(candidatePath) || + allowedPrefixes.some((prefix) => isPathInsideDirectory(candidatePath, prefix)) || + approvedLocalReadPaths.has(candidatePath) ); }