do not invoke SMS or Email sending intent if no contacts are in the group
This commit is contained in:
parent
9cd7c47ace
commit
5e844fe8f0
1 changed files with 10 additions and 2 deletions
|
|
@ -116,11 +116,19 @@ class GroupContactsActivity : SimpleActivity(), RemoveFromGroupListener, Refresh
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun sendSMSToGroup() {
|
private fun sendSMSToGroup() {
|
||||||
sendSMSToContacts(groupContacts)
|
if (groupContacts.isEmpty()) {
|
||||||
|
toast(R.string.no_contacts_found)
|
||||||
|
} else {
|
||||||
|
sendSMSToContacts(groupContacts)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun sendEmailToGroup() {
|
private fun sendEmailToGroup() {
|
||||||
sendEmailToContacts(groupContacts)
|
if (groupContacts.isEmpty()) {
|
||||||
|
toast(R.string.no_contacts_found)
|
||||||
|
} else {
|
||||||
|
sendEmailToContacts(groupContacts)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun assignRingtoneToGroup() {
|
private fun assignRingtoneToGroup() {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue