diff options
Diffstat (limited to 'app/chewy/statuses_index.rb')
-rw-r--r-- | app/chewy/statuses_index.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/chewy/statuses_index.rb b/app/chewy/statuses_index.rb index 1304aeedb..6dd4fb18b 100644 --- a/app/chewy/statuses_index.rb +++ b/app/chewy/statuses_index.rb @@ -3,7 +3,7 @@ class StatusesIndex < Chewy::Index include FormattingHelper - settings index: { refresh_interval: '15m' }, analysis: { + settings index: { refresh_interval: '30s' }, analysis: { filter: { english_stop: { type: 'stop', @@ -33,6 +33,8 @@ class StatusesIndex < Chewy::Index }, } + # We do not use delete_if option here because it would call a method that we + # expect to be called with crutches without crutches, causing n+1 queries index_scope ::Status.unscoped.kept.without_reblogs.includes(:media_attachments, :preloadable_poll) crutch :mentions do |collection| |