mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-11-10 15:56:50 +01:00
Slightly better user profile post filter
This commit is contained in:
@@ -47,7 +47,6 @@ val UserProfilePostKinds1 =
|
|||||||
GenericRepostEvent.KIND,
|
GenericRepostEvent.KIND,
|
||||||
RepostEvent.KIND,
|
RepostEvent.KIND,
|
||||||
LongTextNoteEvent.KIND,
|
LongTextNoteEvent.KIND,
|
||||||
PinListEvent.KIND,
|
|
||||||
PollNoteEvent.KIND,
|
PollNoteEvent.KIND,
|
||||||
HighlightEvent.KIND,
|
HighlightEvent.KIND,
|
||||||
WikiNoteEvent.KIND,
|
WikiNoteEvent.KIND,
|
||||||
@@ -62,6 +61,7 @@ val UserProfilePostKinds2 =
|
|||||||
InteractiveStoryPrologueEvent.KIND,
|
InteractiveStoryPrologueEvent.KIND,
|
||||||
CommentEvent.KIND,
|
CommentEvent.KIND,
|
||||||
VoiceReplyEvent.KIND,
|
VoiceReplyEvent.KIND,
|
||||||
|
PinListEvent.KIND,
|
||||||
)
|
)
|
||||||
|
|
||||||
fun filterUserProfilePosts(
|
fun filterUserProfilePosts(
|
||||||
@@ -70,8 +70,7 @@ fun filterUserProfilePosts(
|
|||||||
): List<RelayBasedFilter> {
|
): List<RelayBasedFilter> {
|
||||||
val relays =
|
val relays =
|
||||||
user.outboxRelays()?.ifEmpty { null }
|
user.outboxRelays()?.ifEmpty { null }
|
||||||
?: user.relaysBeingUsed.keys.ifEmpty { null }
|
?: (user.relaysBeingUsed.keys + LocalCache.relayHints.hintsForKey(user.pubkeyHex))
|
||||||
?: LocalCache.relayHints.hintsForKey(user.pubkeyHex)
|
|
||||||
|
|
||||||
return relays
|
return relays
|
||||||
.map { relay ->
|
.map { relay ->
|
||||||
|
|||||||
Reference in New Issue
Block a user