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

Function withBasePath

public/js/sharedDropView.js:171–177  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

169 }
170
171 function withBasePath(path) {
172 const base = getBasePathFromLocation();
173 const s = String(path || '');
174 if (!base || !s.startsWith('/')) return s;
175 if (s === base || s.startsWith(base + '/')) return s;
176 return base + s;
177 }
178
179 function buildShareUrl(path) {
180 const urlParams = new URLSearchParams(window.location.search || '');

Callers 2

buildShareUrlFunction · 0.70
sharedDropView.jsFile · 0.70

Calls 1

getBasePathFromLocationFunction · 0.70

Tested by

no test coverage detected