Merge branch 'show-reposted-replies' into 'develop'

Display reposted replies with exclude_replies: true

See merge request pleroma/pleroma!3961
This commit is contained in:
marcin mikołajczak 2024-05-17 00:30:35 +00:00
commit 19a1a57895
2 changed files with 4 additions and 2 deletions

View file

@ -0,0 +1 @@
Display reposted replies with exclude_replies: true

View file

@ -979,8 +979,9 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do
defp restrict_replies(query, %{exclude_replies: true}) do
from(
[_activity, object] in query,
where: fragment("?->>'inReplyTo' is null", object.data)
[activity, object] in query,
where:
fragment("?->>'inReplyTo' is null or ?->>'type' = 'Announce'", object.data, activity.data)
)
end