Fix: prevent logging empty context cleared messages (#2861)

This commit is contained in:
Bhavya U
2026-01-14 23:03:18 +00:00
committed by GitHub
parent 7dbfc0862e
commit db70af7edd
@@ -83,7 +83,9 @@ function processDeltasToMessage(deltas: IResponseDelta[]): string {
details.push(`${totalClearedThinkingTurns} thinking turns`);
}
text += `🧹 Context cleared: ${details.join(', ')}`;
if (details.length > 0) {
text += `🧹 Context cleared: ${details.join(', ')}`;
}
}
return text;