Skip to content

Commit 23f2707

Browse files
Guillaume Chausp1ker
authored andcommitted
fix: chrome API check
1 parent d49cd2c commit 23f2707

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/storage.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// If we can, we use the browser extension API to store data
22
// it's async though, so we synchronize changes from an intermediate
33
// storageData object
4-
const useStorage = typeof chrome.storage !== 'undefined'
4+
const useStorage = typeof chrome !== 'undefined' && typeof chrome.storage !== 'undefined'
55

66
let storageData = null
77

0 commit comments

Comments
 (0)