Merge branch 'instance_only_statuses' of https://github.com/masto-donte-com-br/mastodon into hometown-dev

This commit is contained in:
Darius Kazemi
2020-03-02 09:52:41 -08:00
1433 changed files with 34473 additions and 9858 deletions

View File

@ -11,6 +11,10 @@ class FeedManager
# Must be <= MAX_ITEMS or the tracking sets will grow forever
REBLOG_FALLOFF = 40
def with_active_accounts(&block)
Account.joins(:user).where('users.current_sign_in_at > ?', User::ACTIVE_DURATION.ago).find_each(&block)
end
def key(type, id, subtype = nil)
return "feed:#{type}:#{id}" unless subtype