From 34606d609d5761f4d0b7e46965a87344c84065d6 Mon Sep 17 00:00:00 2001 From: kPherox Date: Mon, 9 Aug 2021 09:03:58 +0000 Subject: [PATCH] fix: stream out Create Activity Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3499 --- CHANGELOG.md | 7 ++++++- lib/pleroma/web/activity_pub/side_effects.ex | 7 +++---- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e3e40864..d6bf12d41 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Removed -## 2.4.0 - 2021-08-xx +## 2.4.1 + +### Fixed +- MastodonAPI: Stream out Create activities + +## 2.4.0 - 2021-08-08 ### Changed diff --git a/lib/pleroma/web/activity_pub/side_effects.ex b/lib/pleroma/web/activity_pub/side_effects.ex index b0ec84ade..b82a89896 100644 --- a/lib/pleroma/web/activity_pub/side_effects.ex +++ b/lib/pleroma/web/activity_pub/side_effects.ex @@ -10,7 +10,6 @@ defmodule Pleroma.Web.ActivityPub.SideEffects do collection, and so on. """ alias Pleroma.Activity - alias Pleroma.Activity.Ir.Topics alias Pleroma.Chat alias Pleroma.Chat.MessageReference alias Pleroma.FollowingRelationship @@ -225,6 +224,8 @@ def handle(%{data: %{"type" => "Create"}} = activity, meta) do meta |> add_notifications(notifications) + ap_streamer().stream_out(activity) + {:ok, activity, meta} else e -> Repo.rollback(e) @@ -245,9 +246,7 @@ def handle(%{data: %{"type" => "Announce"}} = object, meta) do if !User.is_internal_user?(user) do Notification.create_notifications(object) - object - |> Topics.get_activity_topics() - |> Streamer.stream(object) + ap_streamer().stream_out(object) end {:ok, object, meta}