I want to edit the device main user's profile from within my application. So I used the `ContentProviderOperation` with `newUpdate` method to collect the changes and then commit them using the `ContentResolver` method's : `applyBatch`. Here is the code i wrote so far:

```
public ContentProviderResult[] updateProfile(Contact userProfile) {
        try {
            ArrayList<ContentProviderOperation> ops = new ArrayList<>();
            ops.add(ContentProviderOperation.newUpdate(ContactsContract.Data.CONTENT_URI)
                    .withValueBackReference(ContactsContract.Data.RAW_CONTACT_ID, Integer.valueOf(userProfile.id))
                    .withValue(ContactsContract.Data.MIMETYPE, ContactsContract.CommonDataKinds.StructuredName.CONTENT_ITEM_TYPE)
                    .withValue(ContactsContract.CommonDataKinds.StructuredName.DISPLAY_NAME, edtName.getText().toString().trim())
                    .build());
            return getContentResolver().applyBatch(ContactsContract.AUTHORITY, ops);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return null;
    }

```

I am getting any run-time Exception but no change is commited! 
Am I missing something?