projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge remote-tracking branch 'origin/develop' into explicit-addressing
[akkoma]
/
lib
/
pleroma
/
web
/
mastodon_api
/
views
/
conversation_view.ex
diff --git
a/lib/pleroma/web/mastodon_api/views/conversation_view.ex
b/lib/pleroma/web/mastodon_api/views/conversation_view.ex
index eb61baa03000676236e3ad336bc683a87f209a9d..af1dcf66dd7588856551d2bee1e8f26b3ace7ca2 100644
(file)
--- a/
lib/pleroma/web/mastodon_api/views/conversation_view.ex
+++ b/
lib/pleroma/web/mastodon_api/views/conversation_view.ex
@@
-3,8
+3,8
@@
defmodule Pleroma.Web.MastodonAPI.ConversationView do
alias Pleroma.Activity
alias Pleroma.Repo
alias Pleroma.Activity
alias Pleroma.Repo
- alias Pleroma.Web.MastodonAPI.AccountView
alias Pleroma.Web.ActivityPub.ActivityPub
alias Pleroma.Web.ActivityPub.ActivityPub
+ alias Pleroma.Web.MastodonAPI.AccountView
alias Pleroma.Web.MastodonAPI.StatusView
def render("participation.json", %{participation: participation, user: user}) do
alias Pleroma.Web.MastodonAPI.StatusView
def render("participation.json", %{participation: participation, user: user}) do
@@
-22,9
+22,14
@@
defmodule Pleroma.Web.MastodonAPI.ConversationView do
last_status = StatusView.render("status.json", %{activity: activity, for: user})
last_status = StatusView.render("status.json", %{activity: activity, for: user})
+ # Conversations return all users except the current user.
+ users =
+ participation.conversation.users
+ |> Enum.reject(&(&1.id == user.id))
+
accounts =
AccountView.render("accounts.json", %{
accounts =
AccountView.render("accounts.json", %{
- users:
participation.conversation.
users,
+ users: users,
as: :user
})
as: :user
})