diff options
author | kaniini <nenolod@gmail.com> | 2018-10-28 05:52:51 +0000 |
---|---|---|
committer | kaniini <nenolod@gmail.com> | 2018-10-28 05:52:51 +0000 |
commit | 39103a91be48abf0e9430c72c9799542ad7e4354 (patch) | |
tree | 084f1796102024beb01bfdc4031695038afd074d /lib | |
parent | 6aeeb322ae7ddf69014be3c28cdaa3954dcb8432 (diff) | |
parent | 72ea54de6e74084d69594c544bcddcc0a991603a (diff) | |
download | pleroma-39103a91be48abf0e9430c72c9799542ad7e4354.tar.gz |
Merge branch 'bugfix/broken-thread-filtering-false-positive' into 'develop'
activitypub: fix possible false positives with broken thread filtering
See merge request pleroma/pleroma!398
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/web/activity_pub/activity_pub.ex | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/pleroma/web/activity_pub/activity_pub.ex b/lib/pleroma/web/activity_pub/activity_pub.ex index 173ca688d..4b8b6eb52 100644 --- a/lib/pleroma/web/activity_pub/activity_pub.ex +++ b/lib/pleroma/web/activity_pub/activity_pub.ex @@ -793,9 +793,10 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do # child def entire_thread_visible_for_user?( - %Activity{data: %{"object" => %{"inReplyTo" => _parent_id}}} = tail, + %Activity{data: %{"object" => %{"inReplyTo" => parent_id}}} = tail, user - ) do + ) + when is_binary(parent_id) do parent = Activity.get_in_reply_to_activity(tail) visible_for_user?(tail, user) && entire_thread_visible_for_user?(parent, user) end |