Avoids lists with the same hexId because the app was pruning events while loading them

This commit is contained in:
Vitor Pamplona
2023-08-25 13:01:49 -04:00
parent 5328740bff
commit e2c011ec60

View File

@@ -236,7 +236,7 @@ abstract class FeedViewModel(val localFilter: FeedFilter<Note>) : ViewModel(), I
checkNotInMainThread()
lastFeedKey = localFilter.feedKey()
val notes = localFilter.loadTop().toImmutableList()
val notes = localFilter.loadTop().distinctBy { it.idHex }.toImmutableList()
val oldNotesState = _feedContent.value
if (oldNotesState is FeedState.Loaded) {