From: Ryan Clarke Date: Tue, 2 Jun 2015 00:29:29 +0000 (-0400) Subject: Fix periods in taxonomies create bad paths X-Git-Tag: v0.15~260 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=18d69d7f8c0b7a0694e649ce2da91ab1063c7c88;p=brevno-suite%2Fhugo Fix periods in taxonomies create bad paths Fixes #1188 --- diff --git a/hugolib/site.go b/hugolib/site.go index fd08c415..4457e105 100644 --- a/hugolib/site.go +++ b/hugolib/site.go @@ -1095,7 +1095,14 @@ func taxonomyRenderer(s *Site, taxes <-chan taxRenderInfo, results chan<- error, n, base = s.newTaxonomyNode(t) - if err := s.renderAndWritePage("taxonomy "+t.singular, base, n, layouts...); err != nil { + dest := base + if viper.GetBool("UglyURLs") { + dest = helpers.Uglify(base + ".html") + } else { + dest = helpers.PrettifyPath(base + "/index.html") + } + + if err := s.renderAndWritePage("taxonomy "+t.singular, dest, n, layouts...); err != nil { results <- err continue }