diff options
author | mkljczk <git@mkljczk.pl> | 2025-02-17 17:55:03 +0100 |
---|---|---|
committer | mkljczk <git@mkljczk.pl> | 2025-02-17 17:55:03 +0100 |
commit | 120fbbc97e4430fb87749ca9271d318889dba7ff (patch) | |
tree | ba06f94284e2178c17dea0c792c1c3eb28a0ab20 /lib | |
parent | ea01b5934f41a13f480221e554723f2b214d67e3 (diff) | |
download | pleroma-120fbbc97e4430fb87749ca9271d318889dba7ff.tar.gz pleroma-120fbbc97e4430fb87749ca9271d318889dba7ff.zip |
Include contentMap in outgoing posts
Signed-off-by: mkljczk <git@mkljczk.pl>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/constants.ex | 1 | ||||
-rw-r--r-- | lib/pleroma/web/activity_pub/transmogrifier.ex | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/lib/pleroma/constants.ex b/lib/pleroma/constants.ex index 2d08cd7a1..42751940a 100644 --- a/lib/pleroma/constants.ex +++ b/lib/pleroma/constants.ex @@ -37,6 +37,7 @@ defmodule Pleroma.Constants do "updated", "emoji", "content", + "contentMap", "summary", "sensitive", "attachment", diff --git a/lib/pleroma/web/activity_pub/transmogrifier.ex b/lib/pleroma/web/activity_pub/transmogrifier.ex index a6f711733..1cea12aa3 100644 --- a/lib/pleroma/web/activity_pub/transmogrifier.ex +++ b/lib/pleroma/web/activity_pub/transmogrifier.ex @@ -6,6 +6,7 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do @moduledoc """ A module to handle coding from internal to wire ActivityPub and back. """ + alias Pleroma.Web.ActivityPub.ObjectValidators.CommonFixes alias Pleroma.Activity alias Pleroma.EctoType.ActivityPub.ObjectValidators alias Pleroma.Maps @@ -167,7 +168,7 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do def fix_quote_url_and_maybe_fetch(object, options \\ []) do quote_url = - case Pleroma.Web.ActivityPub.ObjectValidators.CommonFixes.fix_quote_url(object) do + case CommonFixes.fix_quote_url(object) do %{"quoteUrl" => quote_url} -> quote_url _ -> nil end @@ -720,6 +721,7 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do |> set_reply_to_uri |> set_quote_url |> set_replies + |> CommonFixes.maybe_add_content_map() |> strip_internal_fields |> strip_internal_tags |> set_type |