MCPcopy
hub / github.com/entropic-dev/entropic / has

Method has

services/storage/lib/object-storage.js:87–95  ·  view source on GitHub ↗
(algo, digest)

Source from the content-addressed store, hash-verified

85 }
86
87 async has(algo, digest) {
88 digest = encodeURIComponent(digest);
89 try {
90 await fs.access(`${this.dir}/${algo}/${digest}`);
91 return true;
92 } catch {
93 return false;
94 }
95 }
96
97 async add(algo, digest, data) {
98 digest = encodeURIComponent(digest);

Callers 7

mainFunction · 0.80
visitPackageFunction · 0.80
addBufferMethod · 0.80
addMethod · 0.80
deleteMethod · 0.80
handleCLISessionFunction · 0.80
seasurfFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected