Adjust rss feed template integration

This commit is contained in:
Franck Nijhof
2020-10-26 17:27:54 +01:00
parent 550432b473
commit 4beed33c21

View File

@@ -83,17 +83,19 @@ class RssView(HomeAssistantView):
response += "<rss>\n"
if self._title is not None:
response += " <title>%s</title>\n" % escape(self._title.async_render())
response += " <title>%s</title>\n" % escape(
self._title.async_render(parse_result=False)
)
for item in self._items:
response += " <item>\n"
if "title" in item:
response += " <title>"
response += escape(item["title"].async_render())
response += escape(item["title"].async_render(parse_result=False))
response += "</title>\n"
if "description" in item:
response += " <description>"
response += escape(item["description"].async_render())
response += escape(item["description"].async_render(parse_result=False))
response += "</description>\n"
response += " </item>\n"