diff --git a/src/components/molecules/UserPreferences/Debug.tsx b/src/components/molecules/UserPreferences/Debug.tsx
index eb57c6e88..1615b7fb4 100644
--- a/src/components/molecules/UserPreferences/Debug.tsx
+++ b/src/components/molecules/UserPreferences/Debug.tsx
@@ -15,7 +15,7 @@ export default function Debug(): ReactElement {
defaultChecked={debug === true}
onChange={() => setDebug(!debug)}
/>
- Show geeky debug information in some places.
+ Show geeky information in some places.
)
}
diff --git a/src/providers/UserPreferences.tsx b/src/providers/UserPreferences.tsx
index 4fc5ed276..ef5b9267a 100644
--- a/src/providers/UserPreferences.tsx
+++ b/src/providers/UserPreferences.tsx
@@ -22,14 +22,14 @@ const localStorageKey = 'ocean-user-preferences'
function getLocalStorage() {
const storageParsed =
- window !== undefined &&
+ typeof window !== undefined &&
JSON.parse(window.localStorage.getItem(localStorageKey))
return storageParsed
}
function setLocalStorage(values: UserPreferencesValue) {
return (
- window !== undefined &&
+ typeof window !== undefined &&
window.localStorage.setItem(localStorageKey, JSON.stringify(values))
)
}