From 41b3413f280173f2210b67b660d66b5b56e7ab96 Mon Sep 17 00:00:00 2001 From: Waleed Latif Date: Tue, 2 Jun 2026 20:05:04 -0700 Subject: [PATCH] fix(fathom): skip getDocument when header cache is missing instead of emitting a degraded, un-refreshable record --- apps/sim/connectors/fathom/fathom.ts | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/apps/sim/connectors/fathom/fathom.ts b/apps/sim/connectors/fathom/fathom.ts index 8c65ef43cd..d5aa71fab5 100644 --- a/apps/sim/connectors/fathom/fathom.ts +++ b/apps/sim/connectors/fathom/fathom.ts @@ -498,18 +498,28 @@ export const fathomConnector: ConnectorConfig = { } const header = readCachedHeader(syncContext, externalId) + if (!header) { + logger.warn( + 'No cached header for Fathom meeting; skipping to avoid an un-refreshable record', + { + externalId, + } + ) + return null + } + const content = formatMeetingContent(header, transcript, summary).trim() if (!content) return null return { externalId, - title: header?.title ?? 'Untitled Fathom Meeting', + title: header.title, content, contentDeferred: false, mimeType: 'text/plain', - sourceUrl: header?.sourceUrl, - contentHash: header?.contentHash ?? `fathom:${externalId}`, - metadata: { ...(header?.metadata ?? { recordingId: externalId }) }, + sourceUrl: header.sourceUrl, + contentHash: header.contentHash, + metadata: { ...header.metadata }, } } catch (error) { logger.warn('Failed to get Fathom meeting', {