From: John McFarlane Date: Mon, 7 Dec 2015 05:34:09 +0000 (-0800) Subject: Fix /.xml RSSLink when uglyurls are enabled X-Git-Tag: v0.16~458 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=b1f2b433bc4ec520df81c04493e8e1634293c8e7;p=brevno-suite%2Fhugo Fix /.xml RSSLink when uglyurls are enabled Prior to this commit the root url with uglyurls enabled is "/.xml". This commit relates to #175. --- diff --git a/helpers/url.go b/helpers/url.go index 007d699b..bebcb866 100644 --- a/helpers/url.go +++ b/helpers/url.go @@ -269,6 +269,10 @@ func Uglify(in string) string { } return in } + // /.xml -> /index.xml + if name == "" { + return path.Dir(in) + "index" + ext + } // /section/name.html -> /section/name.html return path.Clean(in) }