MCPcopy Create free account
hub / github.com/docker/getting-started / getItems

Function getItems

app/src/persistence/sqlite.js:40–53  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

38}
39
40async function getItems() {
41 return new Promise((acc, rej) => {
42 db.all('SELECT * FROM todo_items', (err, rows) => {
43 if (err) return rej(err);
44 acc(
45 rows.map(item =>
46 Object.assign({}, item, {
47 completed: item.completed === 1,
48 }),
49 ),
50 );
51 });
52 });
53}
54
55async function getItem(id) {
56 return new Promise((acc, rej) => {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…