Fix issue where sending image when resuming task would be ignored

This commit is contained in:
Saoud Rizwan
2024-08-26 23:06:55 -04:00
parent 273eb3acad
commit c1c8c71f3e

View File

@@ -632,9 +632,10 @@ export class ClaudeDev {
: "") +
`\n\n${this.getPotentiallyRelevantDetails()}`
const newUserContentImages = newUserContent.filter((block) => block.type === "image")
const combinedModifiedOldUserContentWithNewUserContent: UserContent = (
modifiedOldUserContent.filter((block) => block.type !== "text") as UserContent
).concat([{ type: "text", text: combinedText }])
).concat([{ type: "text", text: combinedText }, ...newUserContentImages])
await this.overwriteApiConversationHistory(modifiedApiConversationHistory)
await this.initiateTaskLoop(combinedModifiedOldUserContentWithNewUserContent)