diff --git a/src/components/HistoryView.tsx b/src/components/HistoryView.tsx index 859d567..a491ff7 100644 --- a/src/components/HistoryView.tsx +++ b/src/components/HistoryView.tsx @@ -22,6 +22,12 @@ export function HistoryView({ headers, data, onRevert, onEdit }: HistoryViewProp useEffect(() => { loadHistory(); + }, []); + + useEffect(() => { + if (data.length > 0) { + loadHistory(); + } }, [data]); const loadHistory = async () => {