MCPcopy Create free account
hub / github.com/dylan-sutton-chavez/edge-python / allocDb

Function allocDb

host/storage/src/main/state.js:6–6  ·  view source on GitHub ↗
(idb)

Source from the content-addressed store, hash-verified

4 const dbs = [];
5
6 const allocDb = (idb) => { dbs.push(idb); return dbs.length - 1; };
7 const db = (h) => {
8 if (h < 0 || h >= dbs.length || dbs[h] === null) {
9 throw new Error('invalid db handle: ' + h);

Callers 1

idb.jsFile · 0.85

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected