fix(backend): fix sending N notifications to a single conversation participant

Because of the conversation participant ID being necessary in the email, we launch N jobs to send
notifications, so we need to send the email straight away.

Anonymous participants are always only a single conversation actor
participant, so we're fine

Closes #1384

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2024-01-09 12:23:59 +01:00
parent 681f8dcd04
commit 95379885c8
2 changed files with 23 additions and 4 deletions

View File

@@ -792,7 +792,7 @@ defmodule Mobilizon.Events do
end
end
def get_participant(event_id, actor_id, %{}) do
def get_participant(event_id, actor_id, _params) do
case Participant
|> Repo.get_by(event_id: event_id, actor_id: actor_id)
|> Repo.preload(@participant_preloads) do