mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 06:55:41 +00:00
Code optimization.
This commit is contained in:
+1
-4
@@ -65,10 +65,7 @@ private fun createLastForwardIndicator(identifier: String): MatrixTimelineItem {
|
|||||||
|
|
||||||
private fun List<MatrixTimelineItem>.latestEventIdentifier(): String {
|
private fun List<MatrixTimelineItem>.latestEventIdentifier(): String {
|
||||||
return findLast {
|
return findLast {
|
||||||
when (it) {
|
it is MatrixTimelineItem.Event
|
||||||
is MatrixTimelineItem.Event -> true
|
|
||||||
else -> false
|
|
||||||
}
|
|
||||||
}?.let {
|
}?.let {
|
||||||
(it as MatrixTimelineItem.Event).uniqueId
|
(it as MatrixTimelineItem.Event).uniqueId
|
||||||
} ?: "fake_id"
|
} ?: "fake_id"
|
||||||
|
|||||||
Reference in New Issue
Block a user