MCPcopy Create free account
hub / github.com/tiann/hapi / hasSameAgentSessionIds

Method hasSameAgentSessionIds

hub/src/sync/syncEngine.ts:1393–1402  ·  view source on GitHub ↗
(
        prev: Session['metadata'] | null,
        next: NonNullable<Session['metadata']>
    )

Source from the content-addressed store, hash-verified

1391 }
1392
1393 private hasSameAgentSessionIds(
1394 prev: Session['metadata'] | null,
1395 next: NonNullable<Session['metadata']>
1396 ): boolean {
1397 return (prev?.codexSessionId ?? null) === (next.codexSessionId ?? null)
1398 && (prev?.claudeSessionId ?? null) === (next.claudeSessionId ?? null)
1399 && (prev?.geminiSessionId ?? null) === (next.geminiSessionId ?? null)
1400 && (prev?.opencodeSessionId ?? null) === (next.opencodeSessionId ?? null)
1401 && (prev?.cursorSessionId ?? null) === (next.cursorSessionId ?? null)
1402 }
1403
1404 private triggerDedupIfNeeded(sessionId: string): void {
1405 const session = this.sessionCache.getSession(sessionId)

Callers 1

handleRealtimeEventMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected