MCPcopy Create free account
hub / github.com/diffusionstudio/vits-web / getPath

Function getPath

src/piper.js:1968–1979  ·  view source on GitHub ↗
(node)

Source from the content-addressed store, hash-verified

1966 return { path: current_path, node: current };
1967 },
1968 getPath(node) {
1969 var path;
1970 while (true) {
1971 if (FS.isRoot(node)) {
1972 var mount = node.mount.mountpoint;
1973 if (!path) return mount;
1974 return mount[mount.length - 1] !== '/' ? `${mount}/${path}` : mount + path;
1975 }
1976 path = path ? `${node.name}/${path}` : node.name;
1977 node = node.parent;
1978 }
1979 },
1980 hashName(parentid, name) {
1981 var hash = 0;
1982 for (var i = 0; i < name.length; i++) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected