Skip to content

Commit

Permalink
Fix /.xml RSSLink when uglyurls are enabled
Browse files Browse the repository at this point in the history
Prior to this commit the root url with uglyurls enabled is "/.xml".
This commit relates to gohugoio#175.
  • Loading branch information
jmcfarlane authored and tychoish committed Aug 13, 2017
1 parent f8af118 commit b60626b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions helpers/url.go
Original file line number Diff line number Diff line change
Expand Up @@ -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)
}

0 comments on commit b60626b

Please sign in to comment.