Bug 1300532 - Post: Rename isEnteringReaderMode()'s parameters for more clarity. r=sebastian, a=ritu
authorAndrzej Hunt <ahunt@mozilla.com>
Tue, 06 Sep 2016 15:53:06 -0700
changeset 348139 72689dcc8fe2361742ec88282f820bf381e99174
parent 348138 0bfcfe38984f3ce39f46570d722d5f0cedf32801
child 348140 7db6b94ebda431eb880fb958ebbcd6a9ec3b3eab
push id6389
push userraliiev@mozilla.com
push dateMon, 19 Sep 2016 13:38:22 +0000
treeherdermozilla-beta@01d67bfe6c81 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssebastian, ritu
bugs1300532
milestone50.0a2
Bug 1300532 - Post: Rename isEnteringReaderMode()'s parameters for more clarity. r=sebastian, a=ritu MozReview-Commit-ID: 7Wub31YLGyS
mobile/android/base/java/org/mozilla/gecko/reader/ReaderModeUtils.java
--- a/mobile/android/base/java/org/mozilla/gecko/reader/ReaderModeUtils.java
+++ b/mobile/android/base/java/org/mozilla/gecko/reader/ReaderModeUtils.java
@@ -11,31 +11,31 @@ import android.net.Uri;
 
 public class ReaderModeUtils {
     private static final String LOGTAG = "ReaderModeUtils";
 
     public static String getUrlFromAboutReader(String aboutReaderUrl) {
         return StringUtils.getQueryParameter(aboutReaderUrl, "url");
     }
 
-    public static boolean isEnteringReaderMode(String currentUrl, String newUrl) {
-        if (currentUrl == null || newUrl == null) {
+    public static boolean isEnteringReaderMode(String oldURL, String newURL) {
+        if (oldURL == null || newURL == null) {
             return false;
         }
 
-        if (!AboutPages.isAboutReader(newUrl)) {
+        if (!AboutPages.isAboutReader(newURL)) {
             return false;
         }
 
-        String urlFromAboutReader = getUrlFromAboutReader(newUrl);
+        String urlFromAboutReader = getUrlFromAboutReader(newURL);
         if (urlFromAboutReader == null) {
             return false;
         }
 
-        return urlFromAboutReader.equals(currentUrl);
+        return urlFromAboutReader.equals(oldURL);
     }
 
     public static String getAboutReaderForUrl(String url) {
         return getAboutReaderForUrl(url, -1);
     }
 
     public static String stripAboutReaderUrl(String url) {
         if (!AboutPages.isAboutReader(url)) {