Remove sorting of RSS entrees

- As RSS readers already sort by pubDate
master
Raymon Zutekouw 3 years ago
parent ff984c7046
commit 9b2fd9104d
Signed by: raymon
GPG Key ID: 0E62222846283925
  1. 5
      client/gen.exs

@ -124,10 +124,9 @@ stripForRSS = fn content -> content
|> String.replace("\n", "") |> String.replace("\n", "")
end end
post_feed = post_contents post_feed =
post_contents
|> Enum.map(fn m -> Map.update!(m, :content, stripForRSS) end) |> Enum.map(fn m -> Map.update!(m, :content, stripForRSS) end)
|> Enum.sort_by(fn m -> Map.get(m, :date) end)
|> Enum.reverse()
|> Enum.map(fill_template_pretemplated.(post_feed_item_template)) |> Enum.map(fill_template_pretemplated.(post_feed_item_template))
|> Enum.join("\n") |> Enum.join("\n")
|> (fn v -> %{items: v} end).() |> (fn v -> %{items: v} end).()

Loading…
Cancel
Save