aboutsummaryrefslogtreecommitdiffstats
path: root/lib/settings.coffee
diff options
context:
space:
mode:
Diffstat (limited to 'lib/settings.coffee')
-rw-r--r--lib/settings.coffee4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/settings.coffee b/lib/settings.coffee
index 4fafa7d3..ca4e77b0 100644
--- a/lib/settings.coffee
+++ b/lib/settings.coffee
@@ -55,9 +55,7 @@ Settings =
set: (key, value) ->
# Don't store the value if it is equal to the default, so we can change the defaults in the future.
- # FIXME(smblott). This test is broken for exclusionRules (for which it is never true). In this case, we
- # need some kind of structural equality (or perhaps comparison of JSONified strings).
- if value == @defaults[key]
+ if JSON.stringify(value) == JSON.stringify @defaults[key]
@clear key
else
jsonValue = JSON.stringify value