MCPcopy Index your code
hub / github.com/claude-code-best/claude-code / getEntryPath

Function getEntryPath

src/services/SessionMemory/multiStore.ts:49–58  ·  view source on GitHub ↗
(store: string, key: string)

Source from the content-addressed store, hash-verified

47}
48
49function getEntryPath(store: string, key: string): string {
50 // PR-0a fix: validateKey rejects any '/' or '\' (and other unsafe chars)
51 // up front, so the previous .replace(/[/\\]/g, '_') sanitize is no longer
52 // needed and was actually harmful: it caused 'a/b' and 'a_b' to collide
53 // on the same a_b.md file. Backward compat: pre-existing a_b.md files
54 // (regardless of the original key the user typed) remain readable as
55 // key='a_b' under the new validator.
56 validateKey(key)
57 return join(getStoreDir(store), `${key}.md`)
58}
59
60/** Maximum allowed store name length (OS path component limit). */
61const MAX_STORE_NAME_LENGTH = 255

Callers 4

setEntryFunction · 0.85
getEntryFunction · 0.85
getEntryBoundedFunction · 0.85
deleteEntryFunction · 0.85

Calls 2

getStoreDirFunction · 0.85
validateKeyFunction · 0.50

Tested by

no test coverage detected