Makes sure the relay list contains unique urls.

This commit is contained in:
Vitor Pamplona
2024-01-06 14:36:05 -05:00
parent d269e9e597
commit 6e99e6f4a2
@@ -129,6 +129,7 @@ class NewRelayListViewModel : ViewModel() {
localInfoFeedTypes, localInfoFeedTypes,
) )
} }
.distinctBy { it.url }
.sortedBy { it.downloadCountInBytes } .sortedBy { it.downloadCountInBytes }
.reversed() .reversed()
} else { } else {
@@ -152,6 +153,7 @@ class NewRelayListViewModel : ViewModel() {
it.feedTypes, it.feedTypes,
) )
} }
.distinctBy { it.url }
.sortedBy { it.downloadCountInBytes } .sortedBy { it.downloadCountInBytes }
.reversed() .reversed()
} }