diff --git a/src/index.ts b/src/index.ts index 386fca8ed..372e40d3f 100644 --- a/src/index.ts +++ b/src/index.ts @@ -27,7 +27,7 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => { // Inject correct server baseUrl to ensure SDK client uses dynamic port // Priority: ctx.serverUrl > fallback to existing client baseUrl if (ctx.serverUrl) { - injectServerBaseUrlIntoClient(ctx.client, ctx.serverUrl.toString()) + injectServerBaseUrlIntoClient(ctx.client, ctx.serverUrl.origin) } injectServerAuthIntoClient(ctx.client)