Bug 579604 - Save prefs file after setting up Sync; r=gps
authorSankha Narayan Guria <sankha93@gmail.com>
Mon, 30 Jul 2012 16:05:20 -0700
changeset 100852 cb8e301cc81d327dcf9871cd75a75176d55fead7
parent 100851 5c8ff069f92354c97780e4e94ad40c269cff0ae7
child 100853 cc797e43345c767d71144397d783980d170b084b
push id600
push usergszorc@mozilla.com
push dateMon, 30 Jul 2012 23:05:54 +0000
treeherderservices-central@cb8e301cc81d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgps
bugs579604
milestone17.0a1
Bug 579604 - Save prefs file after setting up Sync; r=gps
services/sync/modules/policies.js
--- a/services/sync/modules/policies.js
+++ b/services/sync/modules/policies.js
@@ -188,16 +188,17 @@ let SyncScheduler = {
         let numItems = subject.succeeded;
         this._log.trace("Engine " + data + " successfully applied " + numItems +
                         " items.");
         if (numItems) {
           this.hasIncomingItems = true;
         }
         break;
       case "weave:service:setup-complete":
+         Services.prefs.savePrefFile(null);
          Svc.Idle.addIdleObserver(this, Svc.Prefs.get("scheduler.idleTime"));
          break;
       case "weave:service:start-over":
          SyncScheduler.setDefaults();
          try {
            Svc.Idle.removeIdleObserver(this, Svc.Prefs.get("scheduler.idleTime"));
          } catch (ex if (ex.result == Cr.NS_ERROR_FAILURE)) {
            // In all likelihood we didn't have an idle observer registered yet.