cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bows...@apache.org
Subject [1/2] android commit: Making framework only apply for http resources for now, so we don't break non-http handling. I had to squash this to make it pretty
Date Wed, 06 Mar 2013 23:31:35 GMT
Making framework only apply for http resources for now, so we don't break non-http handling.
 I had to squash this to make it pretty


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/7388c036
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/7388c036
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/7388c036

Branch: refs/heads/master
Commit: 7388c036d7edab7dc99c306347d6c3a7532b5e30
Parents: 409b9af
Author: Joe Bowser <bowserj@apache.org>
Authored: Wed Mar 6 15:26:13 2013 -0800
Committer: Joe Bowser <bowserj@apache.org>
Committed: Wed Mar 6 15:29:40 2013 -0800

----------------------------------------------------------------------
 .../org/apache/cordova/CordovaWebViewClient.java   |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/7388c036/framework/src/org/apache/cordova/CordovaWebViewClient.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/CordovaWebViewClient.java b/framework/src/org/apache/cordova/CordovaWebViewClient.java
index b1aa0f0..b937d98 100755
--- a/framework/src/org/apache/cordova/CordovaWebViewClient.java
+++ b/framework/src/org/apache/cordova/CordovaWebViewClient.java
@@ -221,8 +221,8 @@ public class CordovaWebViewClient extends WebViewClient {
      */
     @Override
     public WebResourceResponse shouldInterceptRequest(WebView view, String url) {
-        //If something isn't whitelisted, just send a blank response
-        if(!Config.isUrlWhiteListed(url))
+      //If something isn't whitelisted, just send a blank response
+        if(!Config.isUrlWhiteListed(url) && (url.startsWith("http://") || url.startsWith("https://")))
         {
             return getWhitelistResponse();
         }


Mime
View raw message