Merge branch 'fix/reports-ordering' into 'develop'

Do not reverse order of reports. We want newest ones sorted to the top.

Closes #2364

See merge request pleroma/pleroma!3225
This commit is contained in:
feld 2020-12-31 19:24:49 +00:00
commit afe9c152ab
3 changed files with 27 additions and 2 deletions

View file

@ -19,8 +19,7 @@ defmodule Pleroma.Web.AdminAPI.ReportView do
reports:
reports[:items]
|> Enum.map(&Report.extract_report_info/1)
|> Enum.map(&render(__MODULE__, "show.json", &1))
|> Enum.reverse(),
|> Enum.map(&render(__MODULE__, "show.json", &1)),
total: reports[:total]
}
end