MCPcopy Create free account
hub / github.com/Noumena-Network/code / readAsync

Function readAsync

src/utils/secureStorage/plainTextStorage.ts:65–77  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

63 return null
64 },
65 async readAsync(): Promise<SecureStorageData | null> {
66 for (const storagePath of getPlainTextStorageReadPaths()) {
67 try {
68 const data = await getFsImplementation().readFile(storagePath, {
69 encoding: 'utf8',
70 })
71 return jsonParse(data)
72 } catch {
73 continue
74 }
75 }
76 return null
77 },
78 update(data: SecureStorageData): { success: boolean; warning?: string } {
79 // sync IO: called from sync context (SecureStorage interface)
80 try {

Callers

nothing calls this directly

Calls 4

getFsImplementationFunction · 0.85
jsonParseFunction · 0.85
readFileMethod · 0.80

Tested by

no test coverage detected