From 2b1c3c71b751204c8208075ff9e6562e8b44c963 Mon Sep 17 00:00:00 2001 From: Albert S Date: Sat, 20 Aug 2022 10:26:14 +0200 Subject: [PATCH] HandlerFeedGenerator: Use RevisionRenderer --- handlers/handlerfeedgenerator.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/handlers/handlerfeedgenerator.cpp b/handlers/handlerfeedgenerator.cpp index 003af7b..f1ceea1 100644 --- a/handlers/handlerfeedgenerator.cpp +++ b/handlers/handlerfeedgenerator.cpp @@ -1,5 +1,6 @@ #include "handlerfeedgenerator.h" #include "../parser.h" +#include "../revisionrenderer.h" std::vector HandlerFeedGenerator::fetchEntries( std::vector categories) { @@ -67,6 +68,8 @@ std::string HandlerFeedGenerator::generateAtom(const std::vectortempl, *this->database, *this->urlProvider }; + for(const EntryRevisionPair &entry : entries) { const Page &page = entry.first; @@ -87,8 +90,7 @@ std::string HandlerFeedGenerator::generateAtom(const std::vectorurlProvider, current.content))); + atomentry.setVar("entrycontent", utils::html_xss(revisionRenderer.renderContent(current, page.title))); stream << atomentry.render(); } stream << atomfooter;