Expand search range

This commit is contained in:
KMY 2023-04-05 13:55:37 +09:00
parent 462c6e99b6
commit 08e5d96a4a
4 changed files with 10 additions and 2 deletions

View file

@ -35,7 +35,8 @@ class SearchService < BaseService
end
def perform_statuses_search!
definition = parsed_query.apply(StatusesIndex.filter(term: { searchable_by: @account.id }))
# definition = parsed_query.apply(StatusesIndex.filter(term: { searchable_by: @account.id })).order(id: :desc)
definition = parsed_query.apply(StatusesIndex).order(id: :desc)
definition = definition.filter(term: { account_id: @options[:account_id] }) if @options[:account_id].present?