MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / resolveRootUriForContext

Function resolveRootUriForContext

src/lib/editorManager.js:819–828  ·  view source on GitHub ↗
(context = {})

Source from the content-addressed store, hash-verified

817 }
818
819 function resolveRootUriForContext(context = {}) {
820 const uri = context.uri || context.file?.uri;
821 if (!uri) return null;
822 for (const folder of addedFolder) {
823 const base = typeof folder?.url === "string" ? folder.url : "";
824 if (!base) continue;
825 if (uri.startsWith(base)) return base;
826 }
827 return uri;
828 }
829
830 function detachActiveLsp() {
831 if (!lastLspUri) return;

Callers 1

buildLspMetadataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected