mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-23 15:05:45 +00:00
Merge branch 'fix/mastoapi-threadmute-detection' into 'develop'
Mastodon API: Fix thread mute detection See merge request pleroma/pleroma!1548
This commit is contained in:
commit
390329a303
|
@ -26,6 +26,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
||||||
- Federation/MediaProxy not working with instances that have wrong certificate order
|
- Federation/MediaProxy not working with instances that have wrong certificate order
|
||||||
- Mastodon API: Handling of search timeouts (`/api/v1/search` and `/api/v2/search`)
|
- Mastodon API: Handling of search timeouts (`/api/v1/search` and `/api/v2/search`)
|
||||||
- Mastodon API: Embedded relationships not being properly rendered in the Account entity of Status entity
|
- Mastodon API: Embedded relationships not being properly rendered in the Account entity of Status entity
|
||||||
|
- Mastodon API: `muted` in the Status entity, using author's account to determine if the tread was muted
|
||||||
- Mastodon API: Add `account_id`, `type`, `offset`, and `limit` to search API (`/api/v1/search` and `/api/v2/search`)
|
- Mastodon API: Add `account_id`, `type`, `offset`, and `limit` to search API (`/api/v1/search` and `/api/v2/search`)
|
||||||
- Mastodon API, streaming: Fix filtering of notifications based on blocks/mutes/thread mutes
|
- Mastodon API, streaming: Fix filtering of notifications based on blocks/mutes/thread mutes
|
||||||
- ActivityPub C2S: follower/following collection pages being inaccessible even when authentifucated if `hide_followers`/ `hide_follows` was set
|
- ActivityPub C2S: follower/following collection pages being inaccessible even when authentifucated if `hide_followers`/ `hide_follows` was set
|
||||||
|
|
|
@ -168,7 +168,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do
|
||||||
thread_muted? =
|
thread_muted? =
|
||||||
case activity.thread_muted? do
|
case activity.thread_muted? do
|
||||||
thread_muted? when is_boolean(thread_muted?) -> thread_muted?
|
thread_muted? when is_boolean(thread_muted?) -> thread_muted?
|
||||||
nil -> CommonAPI.thread_muted?(user, activity)
|
nil -> (opts[:for] && CommonAPI.thread_muted?(opts[:for], activity)) || false
|
||||||
end
|
end
|
||||||
|
|
||||||
attachment_data = object.data["attachment"] || []
|
attachment_data = object.data["attachment"] || []
|
||||||
|
|
|
@ -2901,8 +2901,10 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIControllerTest do
|
||||||
|
|
||||||
describe "conversation muting" do
|
describe "conversation muting" do
|
||||||
setup do
|
setup do
|
||||||
|
post_user = insert(:user)
|
||||||
user = insert(:user)
|
user = insert(:user)
|
||||||
{:ok, activity} = CommonAPI.post(user, %{"status" => "HIE"})
|
|
||||||
|
{:ok, activity} = CommonAPI.post(post_user, %{"status" => "HIE"})
|
||||||
|
|
||||||
[user: user, activity: activity]
|
[user: user, activity: activity]
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue