diff options
| author | Stephen Blott | 2018-02-18 09:28:32 +0000 | 
|---|---|---|
| committer | Stephen Blott | 2018-02-18 09:28:34 +0000 | 
| commit | 1aeaa8dfdc862ec9839a67fb131f841b744d0aaa (patch) | |
| tree | dfa2352bbeb2f4131c93188cbcdb111914ec9ee0 /lib | |
| parent | 9a5c2802a941a66b6dea4089352314a6e7a3c95a (diff) | |
| download | vimium-1aeaa8dfdc862ec9839a67fb131f841b744d0aaa.tar.bz2 | |
Fix Settings failure in Firefox iframes.
This was failing in iframes in Firefox (causing all sorts of other stuff
to fail).
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/settings.coffee | 3 | 
1 files changed, 2 insertions, 1 deletions
| diff --git a/lib/settings.coffee b/lib/settings.coffee index fd1ef268..4bfbcbf4 100644 --- a/lib/settings.coffee +++ b/lib/settings.coffee @@ -11,7 +11,8 @@  # In all cases except Settings.defaults, values are stored as jsonified strings.  # If the current frame is the Vomnibar or the HUD, then we'll need our Chrome stubs for the tests. -window.chrome ?= window.top?.chrome +# We use "try" because this fails within iframes on Firefox (where failure doesn't actually matter). +try window.chrome ?= window.top?.chrome  storageArea = if chrome.storage.sync? then "sync" else "local" | 
