From e11a86afe9375b40ccda20e6a91b020989e2be4c Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Mon, 9 Feb 2015 13:21:50 +0000 Subject: Fix long-standing bug in sync.coffee. This is wrong: if not key of Settings.defaults It parses as: if (not key) of Settings.defaults and is always false, so we never return here! --- background_scripts/sync.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/background_scripts/sync.coffee b/background_scripts/sync.coffee index ad59f958..d0d501d3 100644 --- a/background_scripts/sync.coffee +++ b/background_scripts/sync.coffee @@ -42,7 +42,7 @@ root.Sync = Sync = # Only ever called from asynchronous synced-storage callbacks (fetchAsync and handleStorageUpdate). storeAndPropagate: (key, value) -> - return if not key of Settings.defaults + return unless key of Settings.defaults return if not @shouldSyncKey key return if value and key of localStorage and localStorage[key] is value defaultValue = Settings.defaults[key] -- cgit v1.2.3