Commit d0535fee authored by Leonardo Aramaki's avatar Leonardo Aramaki

Show read receipt icon to everyone

parent 0afb3a51
...@@ -370,13 +370,12 @@ class ViewModelMapper @Inject constructor( ...@@ -370,13 +370,12 @@ class ViewModelMapper @Inject constructor(
} }
private suspend fun mapMessage(message: Message): MessageViewModel = withContext(CommonPool) { private suspend fun mapMessage(message: Message): MessageViewModel = withContext(CommonPool) {
val senderUsername = message.sender?.username
val sender = getSenderName(message) val sender = getSenderName(message)
val time = getTime(message.timestamp) val time = getTime(message.timestamp)
val avatar = getUserAvatar(message) val avatar = getUserAvatar(message)
val preview = mapMessagePreview(message) val preview = mapMessagePreview(message)
val isTemp = message.isTemporary ?: false val isTemp = message.isTemporary ?: false
val unread = if (settings.messageReadReceiptEnabled() && currentUsername == senderUsername) { val unread = if (settings.messageReadReceiptEnabled()) {
message.unread ?: false message.unread ?: false
} else { } else {
null null
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment