MCPcopy
hub / github.com/simstudioai/sim / folderPath

Function folderPath

apps/sim/lib/copilot/vfs/workflow-aliases.ts:103–114  ·  view source on GitHub ↗
(folderId: string)

Source from the content-addressed store, hash-verified

101
102 const folderPathCache = new Map<string, string>()
103 const folderPath = (folderId: string): string => {
104 const cached = folderPathCache.get(folderId)
105 if (cached) return cached
106
107 const folder = folderMap.get(folderId)
108 if (!folder) return ''
109
110 const safeName = normalizeVfsSegment(folder.name)
111 const path = folder.parentId ? `${folderPath(folder.parentId)}/${safeName}` : safeName
112 folderPathCache.set(folderId, path)
113 return path
114 }
115
116 return workflows.map((workflow) => ({
117 id: workflow.id,

Callers 1

Calls 3

normalizeVfsSegmentFunction · 0.90
getMethod · 0.65
setMethod · 0.65

Tested by

no test coverage detected