Conversation: Also create participations for remote users.
authorlain <lain@soykaf.club>
Mon, 15 Apr 2019 19:45:25 +0000 (21:45 +0200)
committerlain <lain@soykaf.club>
Mon, 15 Apr 2019 19:45:25 +0000 (21:45 +0200)
Needed to get the participating user list.

lib/pleroma/conversation.ex
test/conversation_test.exs

index a77a7cd6ee6df129bfca7bd1b1b02b267f9031aa..5a2a3fc6de302ff0e311918532c679f4c58c5261 100644 (file)
@@ -51,7 +51,7 @@ defmodule Pleroma.Conversation do
          ap_id when is_binary(ap_id) <- activity.data["object"]["context"] do
       {:ok, conversation} = create_for_ap_id(ap_id)
 
-      users = User.get_users_from_set(activity.recipients)
+      users = User.get_users_from_set(activity.recipients, false)
 
       participations =
         Enum.map(users, fn user ->
index 4e3e86c8df0c05d0190d1c0a4ec65be0da69991d..150d55631d884a29a0eedb62cb3d83493b1d1c41 100644 (file)
@@ -31,7 +31,7 @@ defmodule Pleroma.ConversationTest do
 
   test "it creates or updates a conversation and participations for a given DM" do
     har = insert(:user)
-    jafnhar = insert(:user)
+    jafnhar = insert(:user, local: false)
     tridi = insert(:user)
 
     {:ok, activity} =