fix(chat): make resend message non-destructive

Keep normal resend from truncating session history while preserving replace-from-here behavior for regenerate flows.
This commit is contained in:
osmanakkawi
2026-06-15 09:02:48 +03:00
committed by GitHub
parent b20cea347a
commit 71ccd59b54
3 changed files with 67 additions and 19 deletions
+1 -1
View File
@@ -362,7 +362,7 @@ function _openVisionEditor(att, userMsgEl) {
await _saveVisionText();
_closeVisionEditor();
if (userMsgEl && window.chatModule?.resendUserMessage) {
window.chatModule.resendUserMessage(userMsgEl);
window.chatModule.resendUserMessage(userMsgEl, { replaceFromHere: true });
} else if (uiModule?.showToast) {
uiModule.showToast('Saved');
}