Sorts keys before making the filter.

This commit is contained in:
Vitor Pamplona 2024-07-22 13:57:31 -04:00
parent a636f4a786
commit 3c1f57fac0

View File

@ -319,6 +319,9 @@ fun groupByEOSEPresence(notes: Set<Note>): Collection<List<Note>> =
.sorted()
.joinToString(",")
}.values
.map {
it.sortedBy { it.idHex }
}
fun groupByEOSEPresence(users: Iterable<User>): Collection<List<User>> =
users
@ -327,6 +330,9 @@ fun groupByEOSEPresence(users: Iterable<User>): Collection<List<User>> =
.sorted()
.joinToString(",")
}.values
.map {
it.sortedBy { it.pubkeyHex }
}
fun findMinimumEOSEs(notes: List<Note>): Map<String, EOSETime> {
val minLatestEOSEs = mutableMapOf<String, EOSETime>()