Skip to content
Snippets Groups Projects
Commit b7b3e3f2 authored by lain's avatar lain
Browse files

Use inserted_at as sort in search.

parent 678dd4c8
Branches
No related tags found
No related merge requests found
......@@ -213,7 +213,7 @@ defmodule Pleroma.Web.TwitterAPI.TwitterAPI do
where: fragment("to_tsvector('english', ?->'object'->>'content') @@ plainto_tsquery('english', ?)", a.data, ^query),
limit: ^limit,
offset: ^offset,
order_by: [desc: :updated_at] # this one isn't indexed so psql won't take the wrong index.
order_by: [desc: :inserted_at] # this one isn't indexed so psql won't take the wrong index.
activities = Repo.all(q)
activities_to_statuses(activities, %{for: user})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment