Browse Source

Fixed the lack of warning when a non trusted SSL certificate is found if the user creates a new account without the protocol prefix in the URL and both HTTPS and HTTP are available in the server

David A. Velasco 12 năm trước cách đây
mục cha
commit
f3d61ef578

+ 1 - 1
src/com/owncloud/android/authenticator/ConnectionCheckOperation.java

@@ -121,7 +121,7 @@ public class ConnectionCheckOperation extends RemoteOperation {
             if (tryConnection(client, "https://" + mUrl + AccountUtils.STATUS_PATH)) {
                 return new RemoteOperationResult(RemoteOperationResult.ResultCode.OK_SSL);
         			
-            } else if (mLatestResult.isSslRecoverableException()) {
+            } else if (!mLatestResult.isSslRecoverableException()) {
                 
                 Log.d(TAG, "establishing secure connection failed, trying non secure connection");
                 client.setBaseUri(Uri.parse("http://" + mUrl + AccountUtils.STATUS_PATH));