Bug 1276577 - Using Switchboard.isInExperiment() r=sebastian
authorKrishna <k.krish@yahoo.com>
Tue, 31 May 2016 01:16:14 +0800
changeset 339382 d1c3952c299da44bbb1215d73a5c34118f92279e
parent 339381 46b1ef3d9e4f7b0ea7325d05edfc6df313754c72
child 339383 f685593ac3cc4ea3b8d6545e42eb7d225095161a
push id6249
push userjlund@mozilla.com
push dateMon, 01 Aug 2016 13:59:36 +0000
treeherdermozilla-beta@bad9d4f5bf7e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssebastian
bugs1276577
milestone49.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1276577 - Using Switchboard.isInExperiment() r=sebastian MozReview-Commit-ID: F4X1KbLXfqM
mobile/android/base/java/org/mozilla/gecko/dlc/SyncAction.java
--- a/mobile/android/base/java/org/mozilla/gecko/dlc/SyncAction.java
+++ b/mobile/android/base/java/org/mozilla/gecko/dlc/SyncAction.java
@@ -4,16 +4,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 package org.mozilla.gecko.dlc;
 
 import android.content.Context;
 import android.net.Uri;
 import android.util.Log;
 
+import com.keepsafe.switchboard.SwitchBoard;
 import org.json.JSONArray;
 import org.json.JSONException;
 import org.json.JSONObject;
 import org.mozilla.gecko.dlc.catalog.DownloadContent;
 import org.mozilla.gecko.dlc.catalog.DownloadContentBuilder;
 import org.mozilla.gecko.dlc.catalog.DownloadContentCatalog;
 import org.mozilla.gecko.util.Experiments;
 import org.mozilla.gecko.util.IOUtils;
@@ -229,17 +230,17 @@ public class SyncAction extends BaseActi
 
         catalog.markAsDeleted(content);
 
         return true;
     }
 
     protected boolean isSyncEnabledForClient(Context context) {
         // Sync action is behind a switchboard flag for staged rollout.
-        return Experiments.isInExperimentLocal(context, Experiments.DOWNLOAD_CONTENT_CATALOG_SYNC);
+        return SwitchBoard.isInExperiment(context, Experiments.DOWNLOAD_CONTENT_CATALOG_SYNC);
     }
 
     private void logErrorResponse(HttpURLConnection connection) {
         try {
             JSONObject error = fetchJSONResponse(connection);
 
             Log.w(LOGTAG, "Server returned error response:");
             Log.w(LOGTAG, "- Code:    " + error.getInt("code"));