diff --git a/packages/core/src/scheduler/confirmation.ts b/packages/core/src/scheduler/confirmation.ts index 5f2e1d1bc1..3d1ef3b46c 100644 --- a/packages/core/src/scheduler/confirmation.ts +++ b/packages/core/src/scheduler/confirmation.ts @@ -171,7 +171,7 @@ export async function resolveConfirmation( // This prevents the infinite loop issue reported in #7669 outcome = ToolConfirmationOutcome.Cancel; } - } else if (response.payload?.newContent) { + } else if (response.payload && 'newContent' in response.payload) { await handleInlineModification(deps, toolCall, response.payload, signal); outcome = ToolConfirmationOutcome.ProceedOnce; }