Skip to content

Commit

Permalink
Strip all trailing slashes
Browse files Browse the repository at this point in the history
  • Loading branch information
blockmar committed Apr 28, 2015
1 parent e24d205 commit dbbb47a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/sitemap.coffee
Expand Up @@ -83,7 +83,7 @@ module.exports = (grunt) ->
rawUrlPath.replace /\.html/, '/', 'i'
when typeof(extension) == 'object' && !extension.required && !extension.trailingSlash
# Remove extension without trailing slash
rawUrlPath.replace /\.html/, '', 'i'
rawUrlPath.replace /(\.html|\/)$/, '', 'i'
else
# only return path with extension
rawUrlPath
Expand Down
12 changes: 6 additions & 6 deletions tasks/sitemap.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit dbbb47a

Please sign in to comment.