Fix endorsement state display in relationship view

Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
nicole mikołajczyk 2025-07-08 19:08:44 +02:00
commit f031532c41
3 changed files with 5 additions and 3 deletions

View file

@ -0,0 +1 @@
Fix endorsement state display in relationship view

View file

@ -193,7 +193,8 @@ defmodule Pleroma.UserRelationship do
{[:mute], []}
nil ->
{[:block, :mute, :notification_mute, :reblog_mute], [:block, :inverse_subscription]}
{[:block, :mute, :notification_mute, :reblog_mute, :endorsement],
[:block, :inverse_subscription]}
unknown ->
raise "Unsupported :subset option value: #{inspect(unknown)}"

View file

@ -168,9 +168,9 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do
UserRelationship.exists?(
user_relationships,
:endorsement,
target,
reading_user,
&User.endorses?(&2, &1)
target,
&User.endorses?(&1, &2)
)
}
end