Skip to content

Commit 1278511

Browse files
committed
Use Reflect.deleteProperty instead of delete keyword
1 parent 8836097 commit 1278511

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: __tests__/localStorage.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ describe('LocalStorage utilities', () => {
2020
});
2121

2222
it('should not throw exceptions if localStorage is undefined', () => {
23-
delete window.localStorage;
23+
Reflect.deleteProperty(window, 'localStorage');
2424

2525
expect(saveState(data)).toBeUndefined();
2626
expect(loadState()).toBeUndefined();

0 commit comments

Comments
 (0)