This fixes #610
* In useConnection.ts - During initialization, if there is an error immediately following the client sending 'logging/setLevel', pops up a toast with the message `Server declares logging capability but doesn't implement method "logging/setLevel"`
This commit is contained in:
parent
15b58c8142
commit
0d8e8fce4b
1 changed files with 5 additions and 1 deletions
|
|
@ -581,7 +581,11 @@ export function useConnection({
|
|||
setMcpClient(client);
|
||||
setConnectionStatus("connected");
|
||||
} catch (e) {
|
||||
if (lastRequest === "logging/setLevel" && e instanceof McpError && e.code === ErrorCode.MethodNotFound) {
|
||||
if (
|
||||
lastRequest === "logging/setLevel" &&
|
||||
e instanceof McpError &&
|
||||
e.code === ErrorCode.MethodNotFound
|
||||
) {
|
||||
toast({
|
||||
title: "Error",
|
||||
description: `Server declares logging capability but doesn't implement method: "${lastRequest}"`,
|
||||
|
|
|
|||
Loading…
Reference in a new issue