Skip to content

The agent that grows with you

fix(desktop): reject mismatched runtime owner fallback (F1)

yoniebansb78d7f5e3039
diff --git a/apps/desktop/src/app/contrib/hooks/use-background-sync.ts b/apps/desktop/src/app/contrib/hooks/use-background-sync.ts
index 5bf6cbc9505..7c65674533e 100644
--- a/apps/desktop/src/app/contrib/hooks/use-background-sync.ts
+++ b/apps/desktop/src/app/contrib/hooks/use-background-sync.ts
@@ -73,9 +73,9 @@ function preferredActiveTranscriptOwner(
): SessionProfileRoute | undefined {
const runtimeId = runtimeSessionId ?? $activeSessionId.get()
const tiles = $sessionTiles.get().filter(tile => tile.storedSessionId === storedSessionId)
- const activeTile =
- (runtimeId ? tiles.find(tile => tile.runtimeId === runtimeId) : undefined) ??
- (tiles.length === 1 ? tiles[0] : undefined)
+ const activeTile = runtimeId
+ ? tiles.find(tile => tile.runtimeId === runtimeId)
+ : tiles.length === 1 ? tiles[0] : undefined
if (activeTile?.ownerRoute) {
return activeTile.ownerRoute