diff options
-rw-r--r-- | src/Hakyll/Web/Html.hs | 1 | ||||
-rw-r--r-- | tests/Hakyll/Web/Html/Tests.hs | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/src/Hakyll/Web/Html.hs b/src/Hakyll/Web/Html.hs index f5a7ccc..f29a478 100644 --- a/src/Hakyll/Web/Html.hs +++ b/src/Hakyll/Web/Html.hs @@ -124,6 +124,7 @@ toSiteRoot = emptyException . joinPath . map parent emptyException x = x relevant "." = False relevant "/" = False + relevant "./" = False relevant _ = True diff --git a/tests/Hakyll/Web/Html/Tests.hs b/tests/Hakyll/Web/Html/Tests.hs index e150ea2..bad5ebc 100644 --- a/tests/Hakyll/Web/Html/Tests.hs +++ b/tests/Hakyll/Web/Html/Tests.hs @@ -59,6 +59,8 @@ tests = testGroup "Hakyll.Web.Html.Tests" $ concat , "." @=? toSiteRoot "index.html" , "." @=? toSiteRoot "/index.html" , "../.." @=? toSiteRoot "foo/bar/qux" + , ".." @=? toSiteRoot "./foo/bar.html" + , ".." @=? toSiteRoot "/foo/./bar.html" ] , fromAssertions "isExternal" |