Browse Source

Fix subtle home feed filtering bug

closed-social-glitch-2
Eugen 7 years ago
committed by GitHub
parent
commit
3f75f52285
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      app/lib/feed_manager.rb

+ 2
- 1
app/lib/feed_manager.rb View File

@ -9,9 +9,10 @@ class FeedManager
"feed:#{type}:#{id}"
end
# Filter status out of the home feed if it is a reply to someone the user doesn't follow
def filter_status?(status, follower)
replied_to_user = status.reply? ? status.thread.account : nil
(status.reply? && !(follower.id = replied_to_user.id || follower.following?(replied_to_user)))
(status.reply? && !(follower.id == replied_to_user.id || replied_to_user.id == status.account_id || follower.following?(replied_to_user)))
end
def push(timeline_type, account, status)

Loading…
Cancel
Save