X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/6da5d3c212d80042e07c29e9cedbf40643039b4b..ebbc1793e23f67dc7aa2214a542fa2c037fcf4c2:/src/com/owncloud/android/operations/UpdateOCVersionOperation.java diff --git a/src/com/owncloud/android/operations/UpdateOCVersionOperation.java b/src/com/owncloud/android/operations/UpdateOCVersionOperation.java index 4db6363f..a047f110 100644 --- a/src/com/owncloud/android/operations/UpdateOCVersionOperation.java +++ b/src/com/owncloud/android/operations/UpdateOCVersionOperation.java @@ -22,20 +22,19 @@ import org.apache.commons.httpclient.methods.GetMethod; import org.json.JSONException; import org.json.JSONObject; +import com.owncloud.android.authentication.AccountUtils; +import com.owncloud.android.lib.accounts.OwnCloudAccount; +import com.owncloud.android.lib.network.OwnCloudClient; +import com.owncloud.android.lib.operations.common.RemoteOperation; +import com.owncloud.android.lib.operations.common.RemoteOperationResult; +import com.owncloud.android.lib.operations.common.RemoteOperationResult.ResultCode; +import com.owncloud.android.lib.utils.OwnCloudVersion; +import com.owncloud.android.utils.Log_OC; + import android.accounts.Account; import android.accounts.AccountManager; import android.content.Context; -import com.owncloud.android.authentication.AccountAuthenticator; -import com.owncloud.android.authentication.AccountUtils; -import com.owncloud.android.Log_OC; -import com.owncloud.android.oc_framework.accounts.OwnCloudAccount; -import com.owncloud.android.oc_framework.network.webdav.WebdavClient; -import com.owncloud.android.oc_framework.operations.RemoteOperation; -import com.owncloud.android.oc_framework.operations.RemoteOperationResult; -import com.owncloud.android.oc_framework.operations.RemoteOperationResult.ResultCode; -import com.owncloud.android.oc_framework.utils.OwnCloudVersion; - /** * Remote operation that checks the version of an ownCloud server and stores it locally @@ -57,7 +56,7 @@ public class UpdateOCVersionOperation extends RemoteOperation { @Override - protected RemoteOperationResult run(WebdavClient client) { + protected RemoteOperationResult run(OwnCloudClient client) { AccountManager accountMngr = AccountManager.get(mContext); String statUrl = accountMngr.getUserData(mAccount, OwnCloudAccount.Constants.KEY_OC_BASE_URL); statUrl += AccountUtils.STATUS_PATH; @@ -91,15 +90,15 @@ public class UpdateOCVersionOperation extends RemoteOperation { result = new RemoteOperationResult(RemoteOperationResult.ResultCode.INSTANCE_NOT_CONFIGURED); } } - Log_OC.i(TAG, "Check for update of ownCloud server version at " + client.getBaseUri() + ": " + result.getLogMessage()); + Log_OC.i(TAG, "Check for update of ownCloud server version at " + client.getWebdavUri() + ": " + result.getLogMessage()); } catch (JSONException e) { result = new RemoteOperationResult(RemoteOperationResult.ResultCode.INSTANCE_NOT_CONFIGURED); - Log_OC.e(TAG, "Check for update of ownCloud server version at " + client.getBaseUri() + ": " + result.getLogMessage(), e); + Log_OC.e(TAG, "Check for update of ownCloud server version at " + client.getWebdavUri() + ": " + result.getLogMessage(), e); } catch (Exception e) { result = new RemoteOperationResult(e); - Log_OC.e(TAG, "Check for update of ownCloud server version at " + client.getBaseUri() + ": " + result.getLogMessage(), e); + Log_OC.e(TAG, "Check for update of ownCloud server version at " + client.getWebdavUri() + ": " + result.getLogMessage(), e); } finally { if (get != null)