chore: demote reply chunk logs

main
Peter Steinberger 2025-12-23 13:25:56 +00:00
parent e54ed10bc1
commit 96d57a18ee
1 changed files with 9 additions and 7 deletions

View File

@ -588,14 +588,16 @@ async function deliverWebReply(params: {
// Text-only replies // Text-only replies
if (mediaList.length === 0 && textChunks.length) { if (mediaList.length === 0 && textChunks.length) {
for (const chunk of textChunks) { const totalChunks = textChunks.length;
for (const [index, chunk] of textChunks.entries()) {
const chunkStarted = Date.now();
await sendWithRetry(() => msg.reply(chunk), "text"); await sendWithRetry(() => msg.reply(chunk), "text");
} if (!skipLog) {
if (!skipLog) { const durationMs = Date.now() - chunkStarted;
const durationMs = Date.now() - replyStarted; whatsappOutboundLog.debug(
whatsappOutboundLog.info( `Sent chunk ${index + 1}/${totalChunks} to ${msg.from} (${durationMs.toFixed(0)}ms)`,
`Sent reply to ${msg.from} (${durationMs.toFixed(0)}ms)`, );
); }
} }
replyLogger.info( replyLogger.info(
{ {