From 388621f4056912af73173ca412f41f39f155c036 Mon Sep 17 00:00:00 2001 From: Dmitry Konishchev Date: Tue, 2 Apr 2024 08:54:29 +0300 Subject: [PATCH] Fix copyright field rendering in RSS feed The copyright is rendered in footer as `{{ site.Copyright | markdownify }}` which assumes it to be Markdown text, but RSS feed template doesn't ready for Markdown now. --- layouts/_default/rss.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index 89dec2c..87949c9 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -59,7 +59,7 @@ {{ site.Language.LanguageCode }}{{ with $authorEmail }} {{.}}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with $authorEmail }} {{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with site.Copyright }} - {{ . }}{{ end }}{{ if not .Date.IsZero }} + {{ . | markdownify | plainify | strings.TrimPrefix "© " }}{{ end }}{{ if not .Date.IsZero }} {{ (index $pages.ByLastmod.Reverse 0).Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} {{- with .OutputFormats.Get "RSS" }} {{ printf "" .Permalink .MediaType | safeHTML }}