am 013b84da: am 86ada729: Check for null data before writing contact rows to server

Merge commit '013b84dab8d736da21e9103c686e2dbcc30657b7'

* commit '013b84dab8d736da21e9103c686e2dbcc30657b7':
  Check for null data before writing contact rows to server
This commit is contained in:
Marc Blank 2009-09-11 08:15:52 -07:00 committed by Android Git Automerger
commit baf7d8cb70

View File

@ -1556,6 +1556,7 @@ public class ContactsSyncAdapter extends AbstractSyncAdapter {
private void sendPhone(Serializer s, ContentValues cv) throws IOException {
String value = cv.getAsString(Phone.NUMBER);
if (value == null) return;
switch (cv.getAsInteger(Phone.TYPE)) {
case TYPE_WORK2:
s.data(Tags.CONTACTS_BUSINESS2_TELEPHONE_NUMBER, value);
@ -1600,6 +1601,7 @@ public class ContactsSyncAdapter extends AbstractSyncAdapter {
private void sendRelation(Serializer s, ContentValues cv) throws IOException {
String value = cv.getAsString(Relation.DATA);
if (value == null) return;
switch (cv.getAsInteger(Relation.TYPE)) {
case Relation.TYPE_ASSISTANT:
s.data(Tags.CONTACTS_ASSISTANT_NAME, value);