mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 21:32:34 +00:00
Iterate on reactions (#668)
This commit is contained in:
committed by
Benoit Marty
parent
5e455eccb6
commit
43b7acc64e
+4
-1
@@ -16,7 +16,10 @@
|
||||
|
||||
package io.element.android.libraries.matrix.api.timeline.item.event
|
||||
|
||||
import io.element.android.libraries.matrix.api.core.UserId
|
||||
|
||||
data class EventReaction(
|
||||
val key: String,
|
||||
val count: Long
|
||||
val count: Long,
|
||||
val senderIds: List<UserId>
|
||||
)
|
||||
|
||||
+2
-1
@@ -78,7 +78,8 @@ private fun List<Reaction>?.map(): List<EventReaction> {
|
||||
return this?.map {
|
||||
EventReaction(
|
||||
key = it.key,
|
||||
count = it.count.toLong()
|
||||
count = it.count.toLong(),
|
||||
senderIds = it.senders.map { sender -> UserId(sender) }
|
||||
)
|
||||
} ?: emptyList()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user