Fix NPE when adding note rows to Contacts
Change-Id: I51574db9abc45b55f8a7c19d493fdc47bc24b11b
This commit is contained in:
parent
f50c6d1faf
commit
c7897acf56
@ -1334,9 +1334,8 @@ public class ContactsSyncAdapter extends AbstractSyncAdapter {
|
||||
public void addNote(Entity entity, String note) {
|
||||
RowBuilder builder = typedRowBuilder(entity, Note.CONTENT_ITEM_TYPE, -1);
|
||||
ContentValues cv = builder.cv;
|
||||
if (note != null) {
|
||||
note = note.replaceAll("\r\n", "\n");
|
||||
}
|
||||
if (note == null) return;
|
||||
note = note.replaceAll("\r\n", "\n");
|
||||
if (cv != null && cvCompareString(cv, Note.NOTE, note)) {
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user