mirror of
https://github.com/yingziwu/mastodon.git
synced 2026-02-04 03:25:14 +00:00
Change display of blocked and muted quoted users (#36619)
This commit is contained in:
parent
4896d2c4c6
commit
e437bb919f
5 changed files with 98 additions and 13 deletions
|
|
@ -8,13 +8,12 @@ class REST::BaseQuoteSerializer < ActiveModel::Serializer
|
|||
|
||||
# Extra states when a status is unavailable
|
||||
return 'deleted' if object.quoted_status.nil?
|
||||
return 'unauthorized' if status_filter.filtered_for_quote?
|
||||
|
||||
object.state
|
||||
status_filter.filter_state_for_quote || object.state
|
||||
end
|
||||
|
||||
def quoted_status
|
||||
object.quoted_status if object.accepted? && object.quoted_status.present? && !object.quoted_status&.reblog? && !status_filter.filtered_for_quote?
|
||||
object.quoted_status if object.accepted? && object.quoted_status.present? && !object.quoted_status&.reblog? && status_filter.filter_state_for_quote != 'unauthorized'
|
||||
end
|
||||
|
||||
private
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue