OC-2489:Add new check to isSharedSupported
authormasensio <masensio@solidgear.es>
Tue, 21 Jan 2014 10:45:53 +0000 (11:45 +0100)
committermasensio <masensio@solidgear.es>
Tue, 21 Jan 2014 10:45:53 +0000 (11:45 +0100)
oc_framework/src/com/owncloud/android/oc_framework/operations/remote/OwnCloudServerCheckOperation.java

index e43f061..9c5283c 100644 (file)
@@ -79,8 +79,12 @@ public class OwnCloudServerCheckOperation extends RemoteOperation {
     }
     public boolean isSharedSupported() {
         OwnCloudVersion shareServer = new OwnCloudVersion(OCVERSION_SHARED_SUPPORTED);
-        
-        return mOCVersionString.compareTo(shareServer) >= 0; 
+        if (isOnline()) {
+               return mOCVersionString.compareTo(shareServer) >= 0;
+        } else {
+               return false;
+        }
+               
     }
 
     private boolean tryConnection(WebdavClient wc, String urlSt) {