aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Blott2014-04-19 14:52:38 +0100
committerStephen Blott2014-04-19 14:52:38 +0100
commit4083ee6423c10c34c1d0a3fa48e8f4d79c8615df (patch)
treec28227cab884dcc2f33b4e4428dd9a4d9bdd86c0
parent2f343bacd7567cb51901b7f8b54f224ea2f011b2 (diff)
downloadvimium-4083ee6423c10c34c1d0a3fa48e8f4d79c8615df.tar.bz2
Clean up initialization.
-rw-r--r--background_scripts/sync.coffee6
1 files changed, 2 insertions, 4 deletions
diff --git a/background_scripts/sync.coffee b/background_scripts/sync.coffee
index 454aa6fd..1c6c7fb6 100644
--- a/background_scripts/sync.coffee
+++ b/background_scripts/sync.coffee
@@ -30,10 +30,9 @@ root.Sync = Sync =
storage: chrome.storage.sync
doNotSync: [ "settingsVersion", "previousVersion" ]
- register: ->
- chrome.storage.onChanged.addListener (changes, area) -> Sync.listener changes, area
-
+ # This is called in main().
init: ->
+ chrome.storage.onChanged.addListener (changes, area) -> Sync.listener changes, area
@pull()
# Asynchronous fetch from synced storage, called only at startup.
@@ -110,4 +109,3 @@ root.Sync = Sync =
log: (msg) ->
console.log "Sync: #{msg}" if @debug
-Sync.register()