mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-20 08:39:22 +01:00
Show member labels in conversation settings.
This commit is contained in:
committed by
Greyson Parrelli
parent
0199cd24ef
commit
d7b7727aa6
@@ -1289,6 +1289,18 @@ class GroupTable(context: Context?, databaseHelper: SignalDatabase?) :
|
||||
null
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets all member labels in the group. Only includes members that have a non-blank label.
|
||||
*/
|
||||
fun memberLabelsByAci(): Map<ACI, MemberLabel> = buildMap {
|
||||
decryptedGroup.members.forEach { member ->
|
||||
if (member.labelString.isNotBlank()) {
|
||||
val aci = ACI.parseOrNull(member.aciBytes) ?: return@forEach
|
||||
put(aci, MemberLabel(member.labelEmoji, member.labelString))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Throws(BadGroupIdException::class)
|
||||
|
||||
Reference in New Issue
Block a user