Skip to content

Commit 50131c6

Browse files
authored
Merge branch 'main' into handle-empty-json-fields
2 parents 28978ea + cedf02d commit 50131c6

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

client/src/lib/hooks/useConnection.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import {
1010
ListRootsRequestSchema,
1111
ProgressNotificationSchema,
1212
ResourceUpdatedNotificationSchema,
13+
LoggingMessageNotificationSchema,
1314
Request,
1415
Result,
1516
ServerCapabilities,
@@ -258,6 +259,11 @@ export function useConnection({
258259
ResourceUpdatedNotificationSchema,
259260
onNotification,
260261
);
262+
263+
client.setNotificationHandler(
264+
LoggingMessageNotificationSchema,
265+
onNotification,
266+
);
261267
}
262268

263269
if (onStdErrNotification) {

server/src/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,9 @@ const createTransport = async (req: express.Request) => {
6666
return transport;
6767
} else if (transportType === "sse") {
6868
const url = query.url as string;
69-
const headers: HeadersInit = {};
69+
const headers: HeadersInit = {
70+
Accept: "text/event-stream",
71+
};
7072
for (const key of SSE_HEADERS_PASSTHROUGH) {
7173
if (req.headers[key] === undefined) {
7274
continue;

0 commit comments

Comments
 (0)