diff --git a/src/state/__tests__/prefs.test.ts b/src/state/__tests__/prefs.test.ts index d08e668..56d2a17 100644 --- a/src/state/__tests__/prefs.test.ts +++ b/src/state/__tests__/prefs.test.ts @@ -3,13 +3,13 @@ import { getPrefs, setPrefs } from '../prefs'; describe('prefs', () => { beforeEach(() => { + const store: Record = {}; vi.stubGlobal('localStorage', { - store: {} as Record, getItem(key: string) { - return this.store[key] ?? null; + return store[key] ?? null; }, setItem(key: string, value: string) { - this.store[key] = value; + store[key] = value; }, }); });