1
0
mirror of https://git.pleroma.social/sjw/pleroma.git synced 2024-12-23 16:15:03 +01:00

Make search use id index too.

Seems to be faster in general, query planner chooses well.
This commit is contained in:
lain 2018-04-21 09:22:31 +02:00
parent a61e8ac154
commit ff5e957476

View File

@ -521,7 +521,7 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
^query
),
limit: 20,
order_by: [desc: :inserted_at]
order_by: [desc: :id]
)
statuses = Repo.all(q) ++ fetched