Simplify localStorage null check for better readability

This commit is contained in:
Chy-Zaber-Bin-Zahid 2026-01-06 11:08:33 +06:00
parent 11e5e1734b
commit 2da8167bd8

View File

@ -141,7 +141,7 @@ export const getInitialTheme = (themeConfig: SanitizedThemeConfig): string => {
if (
typeof window !== 'undefined' &&
!(localStorage.getItem(LOCAL_STORAGE_KEY_NAME) === null)
localStorage.getItem(LOCAL_STORAGE_KEY_NAME) !== null
) {
const savedTheme = localStorage.getItem(LOCAL_STORAGE_KEY_NAME);