MCPcopy Create free account
hub / github.com/bearlyai/OpenADE / listDocuments

Function listDocuments

projects/openade-module/src/nodeYjsStorage.ts:206–214  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

204
205 return {
206 async listDocuments() {
207 try {
208 const files = await fs.readdir(rootDir)
209 return files.filter((file) => !file.includes(".tmp.")).map((file) => unsanitizeId(file))
210 } catch (error) {
211 if ((error as NodeJS.ErrnoException).code === "ENOENT") return []
212 throw error
213 }
214 },
215 readDocumentUpdate: readUpdate,
216 saveDocumentUpdate: saveUpdate,
217 async deleteDocument(id) {

Callers

nothing calls this directly

Calls 1

unsanitizeIdFunction · 0.70

Tested by

no test coverage detected