Optimize Article query in EdgeCache::BustArticle (#14916)
This commit is contained in:
parent
a2712ffeb0
commit
268ea66dcd
1 changed files with 1 additions and 1 deletions
|
|
@ -85,7 +85,7 @@ module EdgeCache
|
|||
end
|
||||
|
||||
TIMEFRAMES.each do |timestamp, interval|
|
||||
next unless Article.published.where("published_at > ?", timestamp.call).tagged_with(tag)
|
||||
next unless Article.published.where("published_at > ?", timestamp.call).cached_tagged_with_any(tag)
|
||||
.order(public_reactions_count: :desc).limit(3).ids.include?(article.id)
|
||||
|
||||
cache_bust.call("/top/#{interval}")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue