Send event updates to participants
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
parent
7ea96a1f56
commit
5f54228e38
1 changed files with 4 additions and 3 deletions
|
@ -243,13 +243,13 @@ def like(actor, object) do
|
|||
|
||||
@spec update(User.t(), Object.t()) :: {:ok, map(), keyword()}
|
||||
def update(actor, object) do
|
||||
{to, cc} =
|
||||
{to, cc, bcc} =
|
||||
if object["type"] in Pleroma.Constants.actor_types() do
|
||||
# User updates, always public
|
||||
{[Pleroma.Constants.as_public(), actor.follower_address], []}
|
||||
else
|
||||
# Status updates, follow the recipients in the object
|
||||
{object["to"] || [], object["cc"] || []}
|
||||
{object["to"] || [], object["cc"] || [], object["participations"] || []}
|
||||
end
|
||||
|
||||
{:ok,
|
||||
|
@ -259,7 +259,8 @@ def update(actor, object) do
|
|||
"actor" => actor.ap_id,
|
||||
"object" => object,
|
||||
"to" => to,
|
||||
"cc" => cc
|
||||
"cc" => cc,
|
||||
"bcc" => bcc
|
||||
}, []}
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue