catch and show exceptions thrown at saving contacts
This commit is contained in:
parent
3c095463f0
commit
1e38cd8037
1 changed files with 6 additions and 1 deletions
|
|
@ -993,7 +993,12 @@ class ContactsHelper(val activity: Activity) {
|
|||
operations.clear()
|
||||
}
|
||||
}
|
||||
activity.contentResolver.applyBatch(ContactsContract.AUTHORITY, operations)
|
||||
|
||||
try {
|
||||
activity.contentResolver.applyBatch(ContactsContract.AUTHORITY, operations)
|
||||
} catch (e: Exception) {
|
||||
activity.showErrorToast(e)
|
||||
}
|
||||
}
|
||||
|
||||
fun removeContactsFromGroup(contacts: ArrayList<Contact>, groupId: Long) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue