feat(notifications): add missing notifications when an user registers to an event
Closes #1344 Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
@@ -82,6 +82,11 @@ defmodule Mobilizon.Federation.ActivityPub.Actions.Accept do
|
||||
)
|
||||
|
||||
Scheduler.trigger_notifications_for_participant(participant)
|
||||
|
||||
Mobilizon.Service.Activity.Participant.insert_activity(participant,
|
||||
subject: "event_new_participation"
|
||||
)
|
||||
|
||||
participant_as_data = Convertible.model_to_as(participant)
|
||||
audience = Audience.get_audience(participant)
|
||||
|
||||
|
||||
@@ -224,6 +224,10 @@ defmodule Mobilizon.Federation.ActivityPub.Types.Events do
|
||||
cond do
|
||||
Mobilizon.Events.get_default_participant_role(event) == :participant &&
|
||||
role == :participant ->
|
||||
Mobilizon.Service.Activity.Participant.insert_activity(participant,
|
||||
subject: "event_new_participation"
|
||||
)
|
||||
|
||||
{:accept,
|
||||
Actions.Accept.accept(
|
||||
:join,
|
||||
|
||||
Reference in New Issue
Block a user