handle null address
This commit is contained in:
parent
32b8dd4d0e
commit
d5c9d32f86
|
@ -233,7 +233,7 @@ class ContactsHelper(val activity: BaseSimpleActivity) {
|
|||
if (cursor?.moveToFirst() == true) {
|
||||
do {
|
||||
val id = cursor.getIntValue(ContactsContract.Data.RAW_CONTACT_ID)
|
||||
val address = cursor.getStringValue(CommonDataKinds.StructuredPostal.FORMATTED_ADDRESS)
|
||||
val address = cursor.getStringValue(CommonDataKinds.StructuredPostal.FORMATTED_ADDRESS) ?: ""
|
||||
val type = cursor.getIntValue(CommonDataKinds.StructuredPostal.TYPE)
|
||||
|
||||
if (addresses[id] == null) {
|
||||
|
|
Loading…
Reference in New Issue