Bug 1265708 - Pre: remove unused variable r=sebastian
authorAndrzej Hunt <ahunt@mozilla.com>
Thu, 02 Jun 2016 13:51:52 -0700
changeset 341420 1a529039f1a746a54ce1e727ad80595723d302ba
parent 341419 ebfe1808a42d152c40b2ad7bb2198bdf706e0686
child 341421 dc03fe0bad2a83df21395abee0a0574387642982
push id1183
push userraliiev@mozilla.com
push dateMon, 05 Sep 2016 20:01:49 +0000
treeherdermozilla-release@3148731bed45 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssebastian
bugs1265708
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 1265708 - Pre: remove unused variable r=sebastian We already pass the URL inside the JSON object. MozReview-Commit-ID: J4RjxLAzdI
mobile/android/base/java/org/mozilla/gecko/Tab.java
mobile/android/base/java/org/mozilla/gecko/db/LocalURLMetadata.java
mobile/android/base/java/org/mozilla/gecko/db/StubBrowserDB.java
mobile/android/base/java/org/mozilla/gecko/db/URLMetadata.java
--- a/mobile/android/base/java/org/mozilla/gecko/Tab.java
+++ b/mobile/android/base/java/org/mozilla/gecko/Tab.java
@@ -349,17 +349,17 @@ public class Tab {
 
         final ContentResolver cr = mAppContext.getContentResolver();
         final URLMetadata urlMetadata = mDB.getURLMetadata();
 
         final Map<String, Object> data = urlMetadata.fromJSON(metadata);
         ThreadUtils.postToBackgroundThread(new Runnable() {
             @Override
             public void run() {
-                urlMetadata.save(cr, mUrl, data);
+                urlMetadata.save(cr, data);
             }
         });
     }
 
     public ErrorType getErrorType() {
         return mErrorType;
     }
 
--- a/mobile/android/base/java/org/mozilla/gecko/db/LocalURLMetadata.java
+++ b/mobile/android/base/java/org/mozilla/gecko/db/LocalURLMetadata.java
@@ -204,17 +204,17 @@ public class LocalURLMetadata implements
     }
 
     /**
      * Saves a HashMap of metadata into the database. Will iterate through columns
      * in the Database and only save rows with matching keys in the HashMap.
      * Must not be called from UI or Gecko threads.
      */
     @Override
-    public void save(final ContentResolver cr, final String url, final Map<String, Object> data) {
+    public void save(final ContentResolver cr, final Map<String, Object> data) {
         ThreadUtils.assertNotOnUiThread();
         ThreadUtils.assertNotOnGeckoThread();
 
         try {
             ContentValues values = new ContentValues();
 
             for (String key : COLUMNS) {
                 if (data.containsKey(key)) {
--- a/mobile/android/base/java/org/mozilla/gecko/db/StubBrowserDB.java
+++ b/mobile/android/base/java/org/mozilla/gecko/db/StubBrowserDB.java
@@ -44,17 +44,17 @@ class StubURLMetadata implements URLMeta
     }
 
     public Map<String, Map<String, Object>> getForURLs(final ContentResolver cr,
                                                        final List<String> urls,
                                                        final List<String> columns) {
         return new HashMap<String, Map<String, Object>>();
     }
 
-    public void save(final ContentResolver cr, final String url, final Map<String, Object> data) {
+    public void save(final ContentResolver cr, final Map<String, Object> data) {
     }
 }
 
 class StubTabsAccessor implements TabsAccessor {
     public StubTabsAccessor() {
     }
 
     @Override
--- a/mobile/android/base/java/org/mozilla/gecko/db/URLMetadata.java
+++ b/mobile/android/base/java/org/mozilla/gecko/db/URLMetadata.java
@@ -12,10 +12,10 @@ import org.json.JSONObject;
 
 import android.content.ContentResolver;
 
 public interface URLMetadata {
     public Map<String, Object> fromJSON(JSONObject obj);
     public Map<String, Map<String, Object>> getForURLs(final ContentResolver cr,
                                                        final List<String> urls,
                                                        final List<String> columns);
-    public void save(final ContentResolver cr, final String url, final Map<String, Object> data);
+    public void save(final ContentResolver cr, final Map<String, Object> data);
 }