Browse Source

Merge pull request #283 from yuki2006/dev

fix: about scheme
master
Anthony Restaino 9 years ago
parent
commit
f39631bd23
  1. 2
      app/src/main/java/acr/browser/lightning/activity/BrowserActivity.java

2
app/src/main/java/acr/browser/lightning/activity/BrowserActivity.java

@ -1532,7 +1532,7 @@ public abstract class BrowserActivity extends ThemableBrowserActivity implements
boolean containsPeriod = query.contains("."); boolean containsPeriod = query.contains(".");
boolean isIPAddress = (TextUtils.isDigitsOnly(query.replace(".", "")) boolean isIPAddress = (TextUtils.isDigitsOnly(query.replace(".", ""))
&& (query.replace(".", "").length() >= 4) && query.contains(".")); && (query.replace(".", "").length() >= 4) && query.contains("."));
boolean aboutScheme = query.contains("about:"); boolean aboutScheme = query.startsWith("about:");
boolean validURL = (query.startsWith("ftp://") || query.startsWith(Constants.HTTP) boolean validURL = (query.startsWith("ftp://") || query.startsWith(Constants.HTTP)
|| query.startsWith(Constants.FILE) || query.startsWith(Constants.HTTPS)) || query.startsWith(Constants.FILE) || query.startsWith(Constants.HTTPS))
|| isIPAddress; || isIPAddress;

Loading…
Cancel
Save