do not show filter contact source dialog if theres no available sources

This commit is contained in:
tibbi
2018-01-02 23:30:29 +01:00
parent 98424ebd20
commit 22b4dd0a19
2 changed files with 5 additions and 1 deletions

View File

@ -231,7 +231,7 @@ class ContactsHelper(val activity: BaseSimpleActivity) {
cursor = activity.contentResolver.query(uri, projection, null, null, null)
if (cursor?.moveToFirst() == true) {
do {
val name = cursor.getStringValue(ContactsContract.RawContacts.ACCOUNT_NAME)
val name = cursor.getStringValue(ContactsContract.RawContacts.ACCOUNT_NAME) ?: continue
accounts.add(name)
} while (cursor.moveToNext())
}