about summary refs log tree commit diff
path: root/src/lib/api
diff options
context:
space:
mode:
authorEric Bailey <git@esb.lol>2023-09-15 11:34:12 -0500
committerGitHub <noreply@github.com>2023-09-15 09:34:12 -0700
commit8593f41f3619de7ab0755787d32509ab84594c85 (patch)
tree6376667510a835d4adca415bc6bb5bbe5ff5b5cb /src/lib/api
parent188d4893f9f209aae10294bf72fe9f23ed399c28 (diff)
downloadvoidsky-8593f41f3619de7ab0755787d32509ab84594c85.tar.zst
don't thread a self-repost of a self-reply (#1450)
* don't thread a self-repost of a self-reply

* typo
Diffstat (limited to 'src/lib/api')
-rw-r--r--src/lib/api/feed-manip.ts5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/lib/api/feed-manip.ts b/src/lib/api/feed-manip.ts
index 60b0f2641..149859ea9 100644
--- a/src/lib/api/feed-manip.ts
+++ b/src/lib/api/feed-manip.ts
@@ -281,7 +281,10 @@ export class FeedTuner {
 
 function getSelfReplyUri(item: FeedViewPost): string | undefined {
   if (item.reply) {
-    if (AppBskyFeedDefs.isPostView(item.reply.parent)) {
+    if (
+      AppBskyFeedDefs.isPostView(item.reply.parent) &&
+      !AppBskyFeedDefs.isReasonRepost(item.reason) // don't thread reposted self-replies
+    ) {
       return item.reply.parent.author.did === item.post.author.did
         ? item.reply.parent.uri
         : undefined