Skip to content

Commit

Permalink
Merge pull request #19426 from ElectronicBlueberry/fix-ref-sync
Browse files Browse the repository at this point in the history
[24.2] Fix Activity Bar state lost on page reload
  • Loading branch information
ElectronicBlueberry authored Jan 21, 2025
2 parents a7fcdd3 + 34d1272 commit f3e9ff4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client/src/composables/persistentRef.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export function syncRefToLocalStorage<T>(key: string, refToSync: Ref<T>) {
window.localStorage.setItem(key, stringified);
};

if (stored) {
if (stored !== null) {
try {
refToSync.value = parse(stored, typeof refToSync.value as "string" | "number" | "boolean" | "object");
} catch (e) {
Expand Down

0 comments on commit f3e9ff4

Please sign in to comment.