Skip to content

The open source coding agent.

TypeScript

fix(core): cors exception for tauri

Adama02fefe9dc34
diff --git a/packages/opencode/src/server/server.ts b/packages/opencode/src/server/server.ts
index 1c4df2fdc33..a8adebd72c5 100644
--- a/packages/opencode/src/server/server.ts
+++ b/packages/opencode/src/server/server.ts
@@ -111,7 +111,7 @@ export namespace Server {
if (input.startsWith("http://localhost:")) return input
if (input.startsWith("http://127.0.0.1:")) return input
- if (input === "tauri://localhost") return input
+ if (input === "tauri://localhost" || input === "http://tauri.localhost") return input
// *.opencode.ai (https only, adjust if needed)
if (/^https:\/\/([a-z0-9-]+\.)*opencode\.ai$/.test(input)) {