Skip to content
This repository was archived by the owner on Mar 9, 2022. It is now read-only.

Commit

Permalink
fix(rss): fix self atom:link. (#363)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ghosin authored May 15, 2020
1 parent acef6c1 commit 36f59a7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion layouts/index.rss.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@
{{- .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" -}}
</lastBuildDate>
{{- end -}}
<atom:link href="{{ .Permalink }}" rel="self" type="application/rss+xml" />
{{ with .OutputFormats.Get "RSS" }}
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
{{ end }}
{{- range where .Site.RegularPages "Type" "posts" | first (.Site.Params.home.rss | default 10) -}}
{{- dict "page" . "site" .Site | partial "rss/item.html" -}}
{{- end -}}
Expand Down

0 comments on commit 36f59a7

Please sign in to comment.