aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/settings.coffee3
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"