From 30f0aa827dd269cbbc017e696749fb73905d0640 Mon Sep 17 00:00:00 2001 From: Contributor Date: Sat, 21 Mar 2026 11:22:06 +0800 Subject: [PATCH] fix(acp): address code review comments on PR #46863 - Remove redundant getBlockCount() check (accumulatedBlockText.trim() is sufficient) - Simplifies condition for final TTS synthesis - Addresses Codex review feedback --- src/auto-reply/reply/dispatch-acp.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/auto-reply/reply/dispatch-acp.ts b/src/auto-reply/reply/dispatch-acp.ts index 8fc7110fc4c..7fba9c6d28b 100644 --- a/src/auto-reply/reply/dispatch-acp.ts +++ b/src/auto-reply/reply/dispatch-acp.ts @@ -314,7 +314,7 @@ export async function tryDispatchAcpReply(params: { await projector.flush(true); const ttsMode = resolveTtsConfig(params.cfg).mode ?? "final"; const accumulatedBlockText = delivery.getAccumulatedBlockText(); - if (ttsMode === "final" && delivery.getBlockCount() > 0 && accumulatedBlockText.trim()) { + if (ttsMode === "final" && accumulatedBlockText.trim()) { try { const ttsSyntheticReply = await maybeApplyTtsToPayload({ payload: { text: accumulatedBlockText },