mirror of
https://github.com/glitch-soc/mastodon.git
synced 2024-11-23 16:44:04 -05:00
Merge pull request #858 from krainboltgreene/patch-6
Use active record shorthand
This commit is contained in:
commit
2edeb3fe1c
@ -118,7 +118,7 @@ class FeedManager
|
|||||||
|
|
||||||
def filter_from_mentions?(status, receiver_id)
|
def filter_from_mentions?(status, receiver_id)
|
||||||
check_for_blocks = [status.account_id]
|
check_for_blocks = [status.account_id]
|
||||||
check_for_blocks.concat(status.mentions.select('account_id').map(&:account_id))
|
check_for_blocks.concat(status.mentions.pluck(:account_id))
|
||||||
check_for_blocks.concat([status.in_reply_to_account]) if status.reply? && !status.in_reply_to_account_id.nil?
|
check_for_blocks.concat([status.in_reply_to_account]) if status.reply? && !status.in_reply_to_account_id.nil?
|
||||||
|
|
||||||
should_filter = receiver_id == status.account_id # Filter if I'm mentioning myself
|
should_filter = receiver_id == status.account_id # Filter if I'm mentioning myself
|
||||||
|
Loading…
Reference in New Issue
Block a user