MCPcopy Create free account
hub / github.com/error311/FileRise / parentFolderPath

Function parentFolderPath

public/js/aiChat.js:121–127  ·  view source on GitHub ↗
(folder)

Source from the content-addressed store, hash-verified

119}
120
121function parentFolderPath(folder) {
122 const f = normalizeFolderPath(folder);
123 if (f === 'root') return 'root';
124 const idx = f.lastIndexOf('/');
125 if (idx <= 0) return 'root';
126 return f.slice(0, idx);
127}
128
129function getActiveFolder() {
130 return normalizeFolderPath(window.currentFolder || 'root');

Callers 1

Calls 1

normalizeFolderPathFunction · 0.70

Tested by

no test coverage detected