diff --git a/server/app/src/state/historySlice.ts b/server/app/src/state/historySlice.ts index cdb7ca2..587034c 100644 --- a/server/app/src/state/historySlice.ts +++ b/server/app/src/state/historySlice.ts @@ -24,8 +24,16 @@ const loadState = (): HistoryItem[] => { } }; +const loadActiveState = (): number | undefined => { + try { + return JSON.parse(localStorage.getItem("active")!); + } catch (err) { + return undefined; + } +}; + const initialState: HistoryState = { - active: undefined, + active: loadActiveState(), items: loadState() };