Skip to content

The open source coding agent.

TypeScript

fix: server.root is not a function (#1614)

Aiden Cline7a495faa4966
diff --git a/packages/opencode/src/lsp/index.ts b/packages/opencode/src/lsp/index.ts
index 3f141f70ea0..fca80a38753 100644
--- a/packages/opencode/src/lsp/index.ts
+++ b/packages/opencode/src/lsp/index.ts
@@ -67,6 +67,7 @@ export namespace LSP {
}
servers[name] = {
...existing,
+ root: existing?.root ?? (async (_file, app) => app.path.root),
extensions: item.extensions ?? existing.extensions,
spawn: async (_app, root) => {
return {