[home] Home feed update to 21 days and always from database
This commit is contained in:
parent
ecb5c6554c
commit
46ceced444
@ -8,11 +8,11 @@ class HomeFeed < Feed
|
|||||||
end
|
end
|
||||||
|
|
||||||
def get(limit, max_id = nil, since_id = nil, min_id = nil)
|
def get(limit, max_id = nil, since_id = nil, min_id = nil)
|
||||||
if redis.exists?("account:#{@account.id}:regeneration")
|
# if redis.exists?("account:#{@account.id}:regeneration")
|
||||||
from_database(limit, max_id, since_id, min_id)
|
from_database(limit, max_id, since_id, min_id)
|
||||||
else
|
# else
|
||||||
super
|
# super
|
||||||
end
|
# end
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
@ -290,7 +290,7 @@ class Status < ApplicationRecord
|
|||||||
end
|
end
|
||||||
|
|
||||||
def as_home_timeline(account)
|
def as_home_timeline(account)
|
||||||
query = where('created_at > ?', 10.days.ago)
|
query = where('created_at > ?', 21.days.ago)
|
||||||
query.where(visibility: [:public, :unlisted]).or(
|
query.where(visibility: [:public, :unlisted]).or(
|
||||||
where(visibility: [:private]).where('group is null')
|
where(visibility: [:private]).where('group is null')
|
||||||
).or(
|
).or(
|
||||||
|
Loading…
Reference in New Issue
Block a user