forked from potsda.mn/mobilizon
Add relay followers to recipients when sending public entity
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
75fbcb985c
commit
52ea2ff579
|
@ -28,6 +28,19 @@ defmodule Mobilizon.Federation.ActivityPub.Publisher do
|
||||||
Relay.publish(activity)
|
Relay.publish(activity)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
recipients =
|
||||||
|
if public && Config.get([:instance, :allow_relay]) do
|
||||||
|
followers_url = Relay.get_actor().followers_url
|
||||||
|
|
||||||
|
Logger.debug(
|
||||||
|
"Public activity, so adding relay followers URL to recipients: #{inspect(followers_url)}"
|
||||||
|
)
|
||||||
|
|
||||||
|
recipients ++ [followers_url]
|
||||||
|
else
|
||||||
|
recipients
|
||||||
|
end
|
||||||
|
|
||||||
recipients = Enum.uniq(recipients)
|
recipients = Enum.uniq(recipients)
|
||||||
|
|
||||||
{recipients, followers} = convert_followers_in_recipients(recipients)
|
{recipients, followers} = convert_followers_in_recipients(recipients)
|
||||||
|
|
Loading…
Reference in a new issue