File tree Expand file tree Collapse file tree 2 files changed +20
-2
lines changed
Expand file tree Collapse file tree 2 files changed +20
-2
lines changed Original file line number Diff line number Diff line change @@ -190,6 +190,7 @@ export const getTools = <TManifest extends AppManifest>(
190190
191191export interface ListToolsResult {
192192 tools : Tool [ ] ;
193+ [ key : string ] : unknown ;
193194}
194195
195196export type ListToolsMiddleware = RequestMiddleware <
@@ -209,7 +210,7 @@ function registerTools<TManifest extends AppManifest>(
209210) {
210211 // Add map to store slugified names to original names
211212 let toolNames : null | Map < string , string > = null ;
212- const loadTools : ListToolsMiddleware = async ( ) : Promise < ListToolsResult > => {
213+ const loadTools = async ( ) : Promise < ListToolsResult > => {
213214 toolNames ??= new Map < string , string > ( ) ;
214215 const meta = await deco . meta ( ) . then ( ( v ) => v ?. value ) ;
215216 if ( ! meta ) return { tools : [ ] } ;
@@ -237,7 +238,7 @@ function registerTools<TManifest extends AppManifest>(
237238 } ) ;
238239 // Use the original name from the map when invoking
239240 if ( ! toolNames ) {
240- await loadTools ( { request : { } } ) ;
241+ await loadTools ( ) ;
241242 }
242243 const originalName = toolNames ! . get ( req . params . name ) ;
243244 if ( ! originalName ) {
You can’t perform that action at this time.
0 commit comments