Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
TypeScript agentic-aiagentsaiai-agentsaiagentsdeveloper-toolsfunction-callinggpt-4javascriptjsllmllmopsmcppythonremote-mcp-serverssetypescript
refactor(core): remove unnecessary preloadedCustomToolSlugs recomputation
Abir Taheercd269efa065b
diff --git a/ts/packages/core/src/models/ToolRouterSession.ts b/ts/packages/core/src/models/ToolRouterSession.tsindex 38e5c9a0a..39b37fcbf 100644--- a/ts/packages/core/src/models/ToolRouterSession.ts+++ b/ts/packages/core/src/models/ToolRouterSession.ts@@ -51,7 +51,6 @@ import { findCustomToolMapEntryByFinalSlug } from './CustomTool';import { transformProxyParams } from './proxyParamsTransform';import { inlineCustomToolsExperimental } from './inlineCustomToolsPayload';import { transformToolRouterUpdateParams } from '../lib/toolRouterParams';-import { getPreloadedCustomToolSlugs } from './CustomTool';const COMPOSIO_MULTI_EXECUTE_TOOL = 'COMPOSIO_MULTI_EXECUTE_TOOL';export const DIRECT_CUSTOM_TOOL_DESCRIPTION_PREFIX =@@ -68,7 +67,7 @@ export class ToolRouterSession<public preload: ToolRouterSessionPreloadConfig;public configVersion?: number;public warnings: ToolRouterSessionWarning[];- private preloadedCustomToolSlugs: string[];+ private readonly preloadedCustomToolSlugs: string[];private readonly inlineCustomToolsPayload: ToolRouterSessionMetadata['inlineCustomToolsPayload'];/** Singleton session context — shared across all custom tool executions */@@ -485,10 +484,6 @@ export class ToolRouterSession<this.configVersion = response.config_version;this.preload = response.config.preload;this.warnings = response.warnings ?? [];- this.preloadedCustomToolSlugs = getPreloadedCustomToolSlugs(- this.customToolsMap,- this.preload.tools === 'all'- );}// ── Private helpers ──────────────────────────────────────────