From a642817803085d16d320a2754ddc49792fc0a0af Mon Sep 17 00:00:00 2001
From: Paul Lettington <paul-github@plett.co.uk>
Date: Thu, 07 Mar 2019 13:44:08 +0000
Subject: [PATCH] Fix <link/> tag for RSS feeds (#149)
---
layouts/_default/baseof.html | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index 819e2b8..5ba686e 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -62,10 +62,9 @@
<link rel="icon" type="image/png" href="{{ .Site.Params.favicon_32 | default "/images/favicon-32x32.png" | absURL }}" sizes="32x32">
<link rel="icon" type="image/png" href="{{ .Site.Params.favicon_16 | default "/images/favicon-16x16.png" | absURL }}" sizes="16x16">
- {{ if .RSSLink }}
- <link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
- <link href="{{ .RSSLink }}" rel="feed" type="application/rss+xml" title="{{ .Site.Title }}" />
- {{ end }}
+ {{ range .AlternativeOutputFormats -}}
+ {{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
+ {{ end -}}
{{ .Hugo.Generator }}
</head>
--
Gitblit v1.10.0