diff --git a/dom/push/src/PushService.jsm b/dom/push/src/PushService.jsm index 4f9b20f348c6..0149a311a1e1 100644 --- a/dom/push/src/PushService.jsm +++ b/dom/push/src/PushService.jsm @@ -460,6 +460,8 @@ this.PushService = { prefs.observe("serverURL", this); // Used to monitor if the user wishes to disable Push. prefs.observe("connection.enabled", this); + + this._started = true; }, _shutdownWS: function() { diff --git a/dom/push/src/PushServiceLauncher.js b/dom/push/src/PushServiceLauncher.js index 4d371b1eae47..e6afc94ab127 100644 --- a/dom/push/src/PushServiceLauncher.js +++ b/dom/push/src/PushServiceLauncher.js @@ -27,6 +27,7 @@ PushServiceLauncher.prototype = { Services.obs.addObserver(this, "final-ui-startup", true); break; case "final-ui-startup": + Services.obs.removeObserver(this, "final-ui-startup"); if (!Services.prefs.getBoolPref("services.push.enabled")) { return; }