mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-12-23 16:40:29 +00:00
ActivityPub MRF SimplePolicy: fix media stripping
This commit is contained in:
parent
d4a54a90c9
commit
90bbd94614
1 changed files with 2 additions and 1 deletions
|
@ -15,7 +15,8 @@ defmodule Pleroma.Web.ActivityPub.MRF.SimplePolicy do
|
|||
@media_removal Keyword.get(@mrf_policy, :media_removal)
|
||||
defp check_media_removal(actor_info, object) do
|
||||
if actor_info.host in @media_removal do
|
||||
object = Map.delete(object, "attachments")
|
||||
child_object = Map.delete(object["object"], "attachment")
|
||||
object = Map.put(object, "object", child_object)
|
||||
end
|
||||
|
||||
{:ok, object}
|
||||
|
|
Loading…
Reference in a new issue