Move add_to_index / remove_from_index to Pleroma.Actitivy.Search

This commit is contained in:
Ekaterina Vaartis 2021-10-08 12:24:37 +03:00
parent 40280cc273
commit 6beef2d117
2 changed files with 3 additions and 2 deletions

View file

@ -367,8 +367,6 @@ defmodule Pleroma.Activity do
end
defdelegate search(user, query, options \\ []), to: Pleroma.Activity.Search
def add_to_index(_activity), do: nil
def remove_from_index(_object), do: nil
def direct_conversation_id(activity, for_user) do
alias Pleroma.Conversation.Participation

View file

@ -45,6 +45,9 @@ defmodule Pleroma.Activity.Search do
end
end
def add_to_index(_activity), do: nil
def remove_from_index(_object), do: nil
def maybe_restrict_author(query, %User{} = author) do
Activity.Queries.by_author(query, author)
end