Skip to content

Commit 3a2e248

Browse files
committed
Prettier
1 parent e5f6524 commit 3a2e248

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

client/src/lib/hooks/useConnection.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -296,8 +296,10 @@ export function useConnection({
296296
mcpProxyServerUrl.searchParams.append("url", sseUrl);
297297
break;
298298
}
299-
(mcpProxyServerUrl as URL).searchParams.append("transportType", transportType);
300-
299+
(mcpProxyServerUrl as URL).searchParams.append(
300+
"transportType",
301+
transportType,
302+
);
301303

302304
try {
303305
// Inject auth manually instead of using SSEClientTransport, because we're

server/src/index.ts

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ const createTransport = async (req: express.Request): Promise<Transport> => {
9898
return transport;
9999
} else if (transportType === "streamable-http") {
100100
const headers: HeadersInit = {
101-
Accept: "text/event-stream, application/json"
101+
Accept: "text/event-stream, application/json",
102102
};
103103

104104
for (const key of STREAMABLE_HTTP_HEADERS_PASSTHROUGH) {
@@ -129,7 +129,6 @@ const createTransport = async (req: express.Request): Promise<Transport> => {
129129

130130
let backingServerTransport: Transport | undefined;
131131

132-
133132
app.get("/mcp", async (req, res) => {
134133
try {
135134
console.log("New streamable-http connection");
@@ -227,15 +226,18 @@ app.get("/stdio", async (req, res) => {
227226
console.log("Created web app transport");
228227

229228
await webAppTransport.start();
230-
(backingServerTransport as StdioClientTransport).stderr!.on("data", (chunk) => {
229+
(backingServerTransport as StdioClientTransport).stderr!.on(
230+
"data",
231+
(chunk) => {
231232
webAppTransport.send({
232233
jsonrpc: "2.0",
233234
method: "notifications/stderr",
234235
params: {
235236
content: chunk.toString(),
236237
},
237238
});
238-
});
239+
},
240+
);
239241

240242
mcpProxy({
241243
transportToClient: webAppTransport,
@@ -251,7 +253,9 @@ app.get("/stdio", async (req, res) => {
251253

252254
app.get("/sse", async (req, res) => {
253255
try {
254-
console.log("New SSE connection. NOTE: The sse transport is deprecated and has been replaced by streamable-http");
256+
console.log(
257+
"New SSE connection. NOTE: The sse transport is deprecated and has been replaced by streamable-http",
258+
);
255259

256260
try {
257261
await backingServerTransport?.close();

0 commit comments

Comments
 (0)