MCPcopy Create free account
hub / github.com/RioArisk/claudecode_api_RemoteControl / chatCacheWrite

Function chatCacheWrite

app/src/modules/chat-cache.js:46–54  ·  view source on GitHub ↗
(record)

Source from the content-addressed store, hash-verified

44}
45
46export async function chatCacheWrite(record) {
47 const db = await openChatCacheDb();
48 return new Promise((resolve, reject) => {
49 const tx = db.transaction(CHAT_CACHE_STORE, 'readwrite');
50 tx.oncomplete = () => resolve();
51 tx.onerror = () => reject(tx.error || new Error('Failed to write chat cache'));
52 tx.objectStore(CHAT_CACHE_STORE).put(record);
53 });
54}
55
56export async function chatCacheDelete(cacheKey) {
57 const db = await openChatCacheDb();

Callers 1

persistSessionCacheFunction · 0.90

Calls 1

openChatCacheDbFunction · 0.70

Tested by

no test coverage detected