diff --git a/lib/openpod_web/templates/feed/feed.xml.eex b/lib/openpod_web/templates/feed/feed.xml.eex index ca9dcef..595009d 100644 --- a/lib/openpod_web/templates/feed/feed.xml.eex +++ b/lib/openpod_web/templates/feed/feed.xml.eex @@ -2,7 +2,7 @@ <%= @podcast.link %> - ]]> + <%= @podcast.language %> ©2022 ]]> ]]> @@ -21,7 +21,7 @@ <%= @podcast.keywords |> Enum.join(", ") %> ]]> - + <%= @podcast.pubDate |> Calendar.DateTime.Format.rfc2822 %> <![CDATA[<%= @podcast.title %>]]> ]]> diff --git a/lib/openpod_web/views/feed_view.ex b/lib/openpod_web/views/feed_view.ex index 0523e7c..817fb09 100644 --- a/lib/openpod_web/views/feed_view.ex +++ b/lib/openpod_web/views/feed_view.ex @@ -6,4 +6,19 @@ defmodule OpenpodWeb.FeedView do sec = length - (min * 60) |> Integer.to_string |> String.pad_leading(2, "0") "#{min}:#{sec}" end + + def base_url(conn) do + scheme = conn + |> Map.fetch!(:scheme) + |> Atom.to_string + + host = conn + |> Map.fetch!(:host) + + port = conn + |> Map.fetch!(:port) + |> Integer.to_string + + "#{scheme}://#{host}:#{port}" + end end