projects
/
akkoma
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
42a386e
)
Activity search: Fix order of results
author
lain
<lain@soykaf.club>
Thu, 19 Nov 2020 12:20:58 +0000
(13:20 +0100)
committer
lain
<lain@soykaf.club>
Tue, 22 Dec 2020 20:03:01 +0000
(21:03 +0100)
Greatly speeds up the search for RUM.
lib/pleroma/activity/search.ex
patch
|
blob
|
history
diff --git
a/lib/pleroma/activity/search.ex
b/lib/pleroma/activity/search.ex
index ceb365bb3c8b26096a53e42b6637418996a95df8..95ac90acbe4d1b2a1948215caea747db40996d11 100644
(file)
--- a/
lib/pleroma/activity/search.ex
+++ b/
lib/pleroma/activity/search.ex
@@
-27,7
+27,10
@@
defmodule Pleroma.Activity.Search do
|> maybe_restrict_local(user)
|> maybe_restrict_author(author)
|> maybe_restrict_blocked(user)
- |> Pagination.fetch_paginated(%{"offset" => offset, "limit" => limit}, :offset)
+ |> Pagination.fetch_paginated(
+ %{"offset" => offset, "limit" => limit, "skip_order" => true},
+ :offset
+ )
|> maybe_fetch(user, search_query)
end