From: elij Date: Tue, 13 Aug 2013 02:02:43 +0000 (-0700) Subject: fix sanitizeRegex to not strip "dots" X-Git-Tag: v0.9~164^2~1^2~1 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=b13afc4178367d801fc21efa6a4501ce860bc43c;p=brevno-suite%2Fhugo fix sanitizeRegex to not strip "dots" sanitizeRegex was stripping dots in permalinks when generating RenderIndexes (noted during feed/rss generation). permalink was being set to `.../indexxml` instead of `.../index.xml`. Adding "dot" to the regex whitelist fixed the issue. --- diff --git a/hugolib/helpers.go b/hugolib/helpers.go index b2eb3967..80f92c87 100644 --- a/hugolib/helpers.go +++ b/hugolib/helpers.go @@ -27,7 +27,7 @@ import ( "time" ) -var sanitizeRegexp = regexp.MustCompile("[^a-zA-Z0-9/_-]") +var sanitizeRegexp = regexp.MustCompile("[^a-zA-Z0-9/_-.]") // TODO: Make these wrappers private // Wrapper around Fprintf taking verbose flag in account.