better code (ganfra's review)

This commit is contained in:
Benoit Marty 2019-06-20 17:27:15 +02:00
parent 56e0680398
commit 285da114e7
1 changed files with 4 additions and 4 deletions

View File

@ -56,13 +56,13 @@ data class TimelineEvent(
fun getDisambiguatedDisplayName(): String {
return if (isUniqueDisplayName) {
senderName ?: root.senderId
senderName
} else {
senderName?.let {
it + " (" + root.senderId + ")"
senderName?.let { name ->
"$name (${root.senderId})"
}
?: root.senderId
}
?: root.senderId
?: ""
}