Correctly handle empty contact pictures
This commit is contained in:
@@ -40,7 +40,7 @@ public class ContactAdapter extends ArrayAdapter<Contact> {
|
|||||||
TextView name = (TextView) v.findViewById(R.id.contact_name);
|
TextView name = (TextView) v.findViewById(R.id.contact_name);
|
||||||
|
|
||||||
String pic = contact.getPictureBase64();
|
String pic = contact.getPictureBase64();
|
||||||
if (pic != null)
|
if (pic != null && !pic.isEmpty())
|
||||||
picture.setImageBitmap(BoteHelper.decodePicture(pic));
|
picture.setImageBitmap(BoteHelper.decodePicture(pic));
|
||||||
|
|
||||||
name.setText(contact.getName());
|
name.setText(contact.getName());
|
||||||
|
|||||||
Reference in New Issue
Block a user