MCPcopy
hub / github.com/LAION-AI/Open-Assistant / set

Method set

discord-bots/oa-bot-js/src/modules/db.ts:18–22  ·  view source on GitHub ↗
(table, key, value)

Source from the content-addressed store, hash-verified

16 return data[table][key];
17 }
18 set(table, key, value) {
19 const data = JSON.parse(fs.readFileSync(dbPath, "utf-8"));
20 data[table][key] = value;
21 fs.writeFileSync(dbPath, JSON.stringify(data));
22 }
23 delete(key) {
24 const data = JSON.parse(fs.readFileSync(dbPath, "utf-8"));
25 delete data[key];

Callers 10

saveTaskFunction · 0.95
enqueueMethod · 0.80
store_worker_sessionFunction · 0.80
setUserLangFunction · 0.80
executeFunction · 0.80
commandHandlerFunction · 0.80
interactionsHandlerFunction · 0.80
LabelMessagePopupFunction · 0.80
[...nextauth].tsFile · 0.80
users.tsFile · 0.80

Calls 1

parseMethod · 0.45

Tested by

no test coverage detected