diff --git a/src/frontend/src/stores/flowsManagerStore.ts b/src/frontend/src/stores/flowsManagerStore.ts index a75b68015..0204d600c 100644 --- a/src/frontend/src/stores/flowsManagerStore.ts +++ b/src/frontend/src/stores/flowsManagerStore.ts @@ -332,9 +332,11 @@ const useFlowsManagerStore = create((set, get) => ({ const pastLength = past[currentFlowId]?.length ?? 0; if ( pastLength > 0 && - JSON.stringify(past[currentFlowId][pastLength - 1]) !== + JSON.stringify(past[currentFlowId][pastLength - 1]) === JSON.stringify(newState) - ) { + ) + return; + if (pastLength > 0) { past[currentFlowId] = past[currentFlowId].slice( pastLength - defaultOptions.maxHistorySize + 1, pastLength