Add actor to recipients
This commit is contained in:
parent
9a444c0d22
commit
e116e55cab
2 changed files with 18 additions and 0 deletions
|
|
@ -36,6 +36,14 @@ defmodule Pleroma.Web.ActivityPub.ActivityPub do
|
|||
{recipients, to, cc}
|
||||
end
|
||||
|
||||
defp get_recipients(%{"type" => "Create"} = data) do
|
||||
to = data["to"] || []
|
||||
cc = data["cc"] || []
|
||||
actor = data["actor"] || []
|
||||
recipients = (to ++ cc ++ [actor]) |> Enum.uniq()
|
||||
{recipients, to, cc}
|
||||
end
|
||||
|
||||
defp get_recipients(data) do
|
||||
to = data["to"] || []
|
||||
cc = data["cc"] || []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue