refactor(instance): remove remaining bind call sites (#27731)

This commit is contained in:
Shoubhit Dash
2026-05-15 20:04:42 +05:30
committed by GitHub
parent 2d90f325fc
commit fa9a2cb24d
4 changed files with 38 additions and 17 deletions

View File

@@ -256,7 +256,7 @@ const live: Layer.Layer<
const bridge = yield* EffectBridge.make()
const approvedToolsForSession = new Set<string>()
workflowModel.approvalHandler = InstanceState.bind(async (approvalTools) => {
workflowModel.approvalHandler = bridge.bind(async (approvalTools) => {
const uniqueNames = [...new Set(approvalTools.map((t: { name: string }) => t.name))] as string[]
// Auto-approve tools that were already approved in this session
// (prevents infinite approval loops for server-side MCP tools)