From 98e4ed33d0ea580c75c84398d07883c19f8bb45f Mon Sep 17 00:00:00 2001 From: ebolam Date: Fri, 21 Apr 2023 15:18:48 -0400 Subject: [PATCH] Fix for doing a ctrl+a when in the game area but not on any chunk not syncing --- static/koboldai.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/static/koboldai.js b/static/koboldai.js index 92d9b637..3323d2e1 100644 --- a/static/koboldai.js +++ b/static/koboldai.js @@ -3097,6 +3097,7 @@ function gametextwatcher(records) { game_text.append(chunk); } chunk.classList.add("dirty"); + did_deletes = true; } else { //For some reason we've deleted a chunk but it still exists in the DOM. Something is wrong here //Seems to loose the events on the item, but otherwise is OK. DEPLOY HACK!!! @@ -3128,6 +3129,9 @@ function gametextwatcher(records) { } } } + if (did_deletes) { + savegametextchanges(); + } } function savegametextchanges() {