Bug 1081276: Don't use Java assertions. r=rnewman
authorChris Kitching <chriskitching@linux.com>
Fri, 10 Oct 2014 20:40:20 +0100
changeset 233136 1ef3c935199a778ce6591003a480b07bfd846849
parent 233135 f216320d85384686c3fd8b8b2867d2d3349bb837
child 233137 611ffa760b443c10e1d558a2250749c97b6ebc47
push id4187
push userbhearsum@mozilla.com
push dateFri, 28 Nov 2014 15:29:12 +0000
treeherdermozilla-beta@f23cc6a30c11 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrnewman
bugs1081276
milestone35.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 1081276: Don't use Java assertions. r=rnewman
mobile/android/base/webapp/InstallListener.java
--- a/mobile/android/base/webapp/InstallListener.java
+++ b/mobile/android/base/webapp/InstallListener.java
@@ -5,16 +5,17 @@
 
 package org.mozilla.gecko.webapp;
 
 import java.io.File;
 import java.io.IOException;
 
 import org.json.JSONException;
 import org.json.JSONObject;
+import org.mozilla.gecko.Assert;
 import org.mozilla.gecko.GeckoThread;
 
 import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.text.TextUtils;
 import android.util.Log;
@@ -26,18 +27,18 @@ public class InstallListener extends Bro
     private String mManifestUrl;
     private boolean mReceived;
     private File mApkFile;
 
     public InstallListener(String manifestUrl, JSONObject data, File apkFile) {
         mData = data;
         mApkFile = apkFile;
         mManifestUrl = manifestUrl;
-        assert mManifestUrl != null;
-        assert mApkFile != null && mApkFile.exists();
+        Assert.isNotNull(mManifestUrl);
+        Assert.isTrue(mApkFile != null && mApkFile.exists());
     }
 
     public boolean isReceived() {
         return mReceived;
     }
 
     @Override
     public void onReceive(Context context, Intent intent) {