passing git add packages/.git add packages/.

This commit is contained in:
Your Name
2026-05-15 05:32:49 +00:00
parent 26602f97fb
commit efdaf0cb6a
11 changed files with 100 additions and 53 deletions
+11 -1
View File
@@ -398,7 +398,17 @@ export class ContextManager {
});
if (pendingRequest) {
hardenedHistory.pop(); // Remove the pending request from the final output
const last = hardenedHistory[hardenedHistory.length - 1];
if (last && last.content.parts) {
const numPartsToRemove = pendingRequest.content.parts?.length || 0;
if (numPartsToRemove > 0 && last.content.parts.length > numPartsToRemove) {
last.content.parts.splice(-numPartsToRemove);
} else {
hardenedHistory.pop();
}
} else {
hardenedHistory.pop();
}
}
const apiHistory = hardenedHistory.map((h) => h.content);