X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/52bd01bcedf1b8f13c49b67ee40a848bae1a9d40..6bef4abf744cb03d50dd4ecff121c20a1e267aab:/src/com/owncloud/android/syncadapter/ContactSyncAdapter.java diff --git a/src/com/owncloud/android/syncadapter/ContactSyncAdapter.java b/src/com/owncloud/android/syncadapter/ContactSyncAdapter.java index b82a4003..d3ab06c1 100644 --- a/src/com/owncloud/android/syncadapter/ContactSyncAdapter.java +++ b/src/com/owncloud/android/syncadapter/ContactSyncAdapter.java @@ -1,6 +1,8 @@ -/* ownCloud Android client application +/** + * ownCloud Android client application + * * Copyright (C) 2012 Bartek Przybylski - * Copyright (C) 2012-2013 ownCloud Inc. + * Copyright (C) 2015 ownCloud Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2, @@ -24,8 +26,9 @@ import java.io.IOException; import org.apache.http.client.methods.HttpPut; import org.apache.http.entity.ByteArrayEntity; -import com.owncloud.android.AccountUtils; -import com.owncloud.android.authentication.AccountAuthenticator; +import com.owncloud.android.authentication.AccountUtils; +import com.owncloud.android.lib.common.accounts.AccountUtils.Constants; + import android.accounts.Account; import android.accounts.AccountManager; @@ -52,7 +55,7 @@ public class ContactSyncAdapter extends AbstractOwnCloudSyncAdapter { public void onPerformSync(Account account, Bundle extras, String authority, ContentProviderClient provider, SyncResult syncResult) { setAccount(account); - setContentProvider(provider); + setContentProviderClient(provider); Cursor c = getLocalContacts(false); if (c.moveToFirst()) { do { @@ -91,7 +94,7 @@ public class ContactSyncAdapter extends AbstractOwnCloudSyncAdapter { AccountManager am = getAccountManager(); @SuppressWarnings("deprecation") String uri = am.getUserData(getAccount(), - AccountAuthenticator.KEY_OC_URL).replace( + Constants.KEY_OC_URL).replace( AccountUtils.WEBDAV_PATH_2_0, AccountUtils.CARDDAV_PATH_2_0); uri += "/addressbooks/" + getAccount().name.substring(0,