Fixes issue with super large follow lists.
This commit is contained in:
@@ -112,7 +112,7 @@ object NostrHomeDataSource : AmethystNostrDataSource("HomeFeed") {
|
|||||||
|
|
||||||
fun createFollowMetadataAndReleaseFilter(): TypedFilter? {
|
fun createFollowMetadataAndReleaseFilter(): TypedFilter? {
|
||||||
val follows = account.liveHomeFollowLists.value?.users
|
val follows = account.liveHomeFollowLists.value?.users
|
||||||
val followSet = follows?.plus(account.userProfile().pubkeyHex)?.toList()?.ifEmpty { null }
|
val followSet = follows?.plus(account.userProfile().pubkeyHex)?.shuffled()?.ifEmpty { null }
|
||||||
|
|
||||||
return if (followSet != null) {
|
return if (followSet != null) {
|
||||||
TypedFilter(
|
TypedFilter(
|
||||||
@@ -124,7 +124,7 @@ object NostrHomeDataSource : AmethystNostrDataSource("HomeFeed") {
|
|||||||
MetadataEvent.KIND,
|
MetadataEvent.KIND,
|
||||||
AdvertisedRelayListEvent.KIND,
|
AdvertisedRelayListEvent.KIND,
|
||||||
),
|
),
|
||||||
authors = followSet,
|
authors = followSet.take(500),
|
||||||
since =
|
since =
|
||||||
latestEOSEs.users[account.userProfile()]
|
latestEOSEs.users[account.userProfile()]
|
||||||
?.followList
|
?.followList
|
||||||
|
|||||||
Reference in New Issue
Block a user