From 8b1d8bf26452f3ce8b38228a39755a6b8e18775a Mon Sep 17 00:00:00 2001 From: Mitchell Riedstra Date: Thu, 15 Jul 2021 01:10:41 -0400 Subject: Start on the example website. Remove some chunks of code. Fix up author handling in the feeds. --- cmd/server/feed.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'cmd/server/feed.go') diff --git a/cmd/server/feed.go b/cmd/server/feed.go index 2d4a75b..073097b 100644 --- a/cmd/server/feed.go +++ b/cmd/server/feed.go @@ -189,6 +189,15 @@ func (a *App) FeedHandler(w http.ResponseWriter, r *http.Request) { Links: []Link{Link{Href: strings.Join([]string{a.SiteURL, p.Path()}, "/")}}, } + if p.AuthorName != "" { + entry.Author = &Author{ + Name: p.AuthorName, + } + if p.AuthorEmail != "" { + entry.Author.Email = p.AuthorEmail + } + } + if addContent { entry.Content = &Content{Type: "html", Data: content.String()} } -- cgit v1.2.3