feat(claude-code-hooks): improve session handling and add tests
🤖 Generated with assistance of OhMyOpenCode
This commit is contained in:
@@ -97,6 +97,10 @@ export function clearTranscriptCache(sessionId?: string): void {
|
||||
}
|
||||
}
|
||||
|
||||
export function hasTranscriptCacheEntry(sessionId: string): boolean {
|
||||
return transcriptCache.has(sessionId)
|
||||
}
|
||||
|
||||
function isCacheValid(entry: TranscriptCacheEntry): boolean {
|
||||
return Date.now() - entry.createdAt < TRANSCRIPT_CACHE_TTL_MS
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user