{:ok, activity, _} <- Pipeline.common_pipeline(emoji_react, local: true) do
{:ok, activity}
else
- _ ->
- {:error, dgettext("errors", "Could not add reaction emoji")}
+ _ -> {:error, dgettext("errors", "Could not add reaction emoji")}
end
end
|> check_expiry_date()
end
- def listen(user, data) do
- with {:ok, draft} <- ActivityDraft.listen(user, data) do
- ActivityPub.listen(draft.changes)
- end
- end
-
def post(user, %{status: _} = data) do
with {:ok, draft} <- ActivityDraft.create(user, data) do
ActivityPub.create(draft.changes, draft.preview?)