Permalink
Browse files

hugolib: Fix RSSLink vs RSS Output Format

Fixes #3450
  • Loading branch information...
bep committed May 17, 2017
1 parent b6ea492 commit e682fcc62233b47cf5bdcaf598ac0657ef089471
Showing with 10 additions and 1 deletion.
  1. +5 −1 hugolib/site.go
  2. +5 −0 hugolib/site_output_test.go
View
@@ -1139,7 +1139,11 @@ func (s *Site) initializeSiteInfo() {
s: s,
}
s.Info.RSSLink = s.permalink(lang.GetString("rssURI"))
rssOutputFormat, found := s.outputFormats[KindHome].GetByName(output.RSSFormat.Name)
if found {
s.Info.RSSLink = s.permalink(rssOutputFormat.BaseFilename())
}
}
func (s *Site) dataDir() string {
@@ -284,4 +284,9 @@ baseName = "feed"
th.assertFileContent("public/feed.xml", "Recent content on")
s := h.Sites[0]
//Issue #3450
require.Equal(t, "http://example.com/blog/feed.xml", s.Info.RSSLink)
}

0 comments on commit e682fcc

Please sign in to comment.