File tree Expand file tree Collapse file tree 3 files changed +14
-6
lines changed
Expand file tree Collapse file tree 3 files changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -616,7 +616,9 @@ export class Client<
616616 switch ( method as ClientNotification [ 'method' ] ) {
617617 case 'notifications/roots/list_changed' :
618618 if ( ! this . _capabilities . roots ?. listChanged ) {
619- throw new UnsupportedCapabilityError ( `Client does not support roots list changed notifications (required for ${ method } )` ) ;
619+ throw new UnsupportedCapabilityError (
620+ `Client does not support roots list changed notifications (required for ${ method } )`
621+ ) ;
620622 }
621623 break ;
622624
Original file line number Diff line number Diff line change 55 * @experimental
66 */
77
8- import { UnsupportedCapabilityError } from " ../../types/types.js" ;
8+ import { UnsupportedCapabilityError } from ' ../../types/types.js' ;
99
1010/**
1111 * Type representing the task requests capability structure.
@@ -40,7 +40,9 @@ export function assertToolsCallTaskCapability(
4040 switch ( method ) {
4141 case 'tools/call' :
4242 if ( ! requests . tools ?. call ) {
43- throw new UnsupportedCapabilityError ( `${ entityName } does not support task creation for tools/call (required for ${ method } )` ) ;
43+ throw new UnsupportedCapabilityError (
44+ `${ entityName } does not support task creation for tools/call (required for ${ method } )`
45+ ) ;
4446 }
4547 break ;
4648
@@ -73,13 +75,17 @@ export function assertClientRequestTaskCapability(
7375 switch ( method ) {
7476 case 'sampling/createMessage' :
7577 if ( ! requests . sampling ?. createMessage ) {
76- throw new UnsupportedCapabilityError ( `${ entityName } does not support task creation for sampling/createMessage (required for ${ method } )` ) ;
78+ throw new UnsupportedCapabilityError (
79+ `${ entityName } does not support task creation for sampling/createMessage (required for ${ method } )`
80+ ) ;
7781 }
7882 break ;
7983
8084 case 'elicitation/create' :
8185 if ( ! requests . elicitation ?. create ) {
82- throw new UnsupportedCapabilityError ( `${ entityName } does not support task creation for elicitation/create (required for ${ method } )` ) ;
86+ throw new UnsupportedCapabilityError (
87+ `${ entityName } does not support task creation for elicitation/create (required for ${ method } )`
88+ ) ;
8389 }
8490 break ;
8591
Original file line number Diff line number Diff line change @@ -239,7 +239,7 @@ export enum ErrorCode {
239239
240240 // MCP-specific error codes
241241 UrlElicitationRequired = - 32042 ,
242- UnsupportedCapability = - 32043
242+ UnsupportedCapability = - 32043
243243}
244244
245245/**
You can’t perform that action at this time.
0 commit comments