fix no-language-specified federation
ci/woodpecker/push/woodpecker Pipeline is pending Details

This commit is contained in:
FloatingGhost 2023-01-11 15:25:34 +00:00
parent 22068f0853
commit 78c44f31ca
1 changed files with 4 additions and 1 deletions

View File

@ -145,7 +145,10 @@ defmodule Pleroma.Web.CommonAPI.ActivityDraft do
end
end
defp language(draft), do: draft
defp language(%{content_html: content} = draft) do
# Use a default language if no language is specified
%__MODULE__{draft | content_map: %{"en" => content}}
end
defp visibility(%{params: params} = draft) do
case CommonAPI.get_visibility(params, draft.in_reply_to, draft.in_reply_to_conversation) do