From fc15c25889835e45f24b533f610196ae117459a7 Mon Sep 17 00:00:00 2001 From: Lain Soykaf Date: Thu, 25 Dec 2025 12:50:55 +0400 Subject: [PATCH] Transmogrifier: Only set replies on objects, not activities. --- lib/pleroma/web/activity_pub/transmogrifier.ex | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/pleroma/web/activity_pub/transmogrifier.ex b/lib/pleroma/web/activity_pub/transmogrifier.ex index 823daac54..6ced6c27d 100644 --- a/lib/pleroma/web/activity_pub/transmogrifier.ex +++ b/lib/pleroma/web/activity_pub/transmogrifier.ex @@ -742,8 +742,9 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do Inline first page of the `replies` collection, containing any replies in chronological order. """ - def set_replies(obj_data) do - with obj_ap_id when obj_ap_id != nil <- obj_data["id"], + def set_replies(%{"type" => type} = obj_data) + when type in Pleroma.Constants.status_object_types() do + with obj_ap_id when is_binary(obj_ap_id) <- obj_data["id"], limit when limit > 0 <- Pleroma.Config.get([:activitypub, :note_replies_output_limit], 0), collection <- @@ -757,6 +758,8 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do end end + def set_replies(obj_data), do: obj_data + # Prepares the object of an outgoing create activity. def prepare_object(object) do object