fix: stream out Create Activity
authorkPherox <admin@mail.kr-kp.com>
Mon, 9 Aug 2021 09:03:58 +0000 (09:03 +0000)
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Fri, 13 Aug 2021 15:54:51 +0000 (17:54 +0200)
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3499

CHANGELOG.md
lib/pleroma/web/activity_pub/side_effects.ex

index 4e3e408646f1aad4403ca427ee2d67914bf62472..d6bf12d4106e5d7a7fcaae7b1d4089f498966c29 100644 (file)
@@ -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
 
index b0ec84ade17cb44309759b0de73861c114159036..b82a89896b4e5518cbd4f95a4a8c04b8143c7e2b 100644 (file)
@@ -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 @@ defmodule Pleroma.Web.ActivityPub.SideEffects do
         meta
         |> add_notifications(notifications)
 
+      ap_streamer().stream_out(activity)
+
       {:ok, activity, meta}
     else
       e -> Repo.rollback(e)
@@ -245,9 +246,7 @@ defmodule Pleroma.Web.ActivityPub.SideEffects 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}