1
0
Fork 1
mirror of https://akkoma.dev/AkkomaGang/akkoma.git synced 2024-12-25 04:53:06 +00:00

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

This commit is contained in:
Mark Felder 2020-12-30 14:22:48 -06:00
parent 38924166eb
commit 744b34709d

View file

@ -19,8 +19,7 @@ def render("index.json", %{reports: reports}) 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