mirror of
https://github.com/element-hq/element-android
synced 2024-11-28 05:31:21 +03:00
Fix a crash (#548)
This commit is contained in:
parent
6ceac578a3
commit
f51568b331
1 changed files with 8 additions and 6 deletions
|
@ -92,10 +92,11 @@ class PhoneBookController @Inject constructor(
|
|||
avatarRenderer(avatarRenderer)
|
||||
}
|
||||
mappedContact.emails
|
||||
.filter { !onlyBoundContacts || it.matrixId != null }
|
||||
.forEach {
|
||||
.forEachIndexed { index, it ->
|
||||
if (onlyBoundContacts && it.matrixId == null) return@forEachIndexed
|
||||
|
||||
contactDetailItem {
|
||||
id("$mappedContact.id${it.email}")
|
||||
id("${mappedContact.id}-$index-${it.email}")
|
||||
threePid(it.email)
|
||||
matrixId(it.matrixId)
|
||||
clickListener {
|
||||
|
@ -108,10 +109,11 @@ class PhoneBookController @Inject constructor(
|
|||
}
|
||||
}
|
||||
mappedContact.msisdns
|
||||
.filter { !onlyBoundContacts || it.matrixId != null }
|
||||
.forEach {
|
||||
.forEachIndexed { index, it ->
|
||||
if (onlyBoundContacts && it.matrixId == null) return@forEachIndexed
|
||||
|
||||
contactDetailItem {
|
||||
id("$mappedContact.id${it.phoneNumber}")
|
||||
id("${mappedContact.id}-$index-${it.phoneNumber}")
|
||||
threePid(it.phoneNumber)
|
||||
matrixId(it.matrixId)
|
||||
clickListener {
|
||||
|
|
Loading…
Reference in a new issue