mirror of
https://github.com/gohugoio/hugo.git
synced 2025-05-02 08:30:07 +03:00
parent
17055d1fa7
commit
2d217cba51
2 changed files with 2 additions and 1 deletions
|
@ -102,7 +102,7 @@ func (p *PathSpec) UnicodeSanitize(s string) string {
|
|||
)
|
||||
|
||||
for i, r := range source {
|
||||
isAllowed := r == '.' || r == '/' || r == '\\' || r == '_' || r == '#' || r == '+' || r == '~' || r == '-'
|
||||
isAllowed := r == '.' || r == '/' || r == '\\' || r == '_' || r == '#' || r == '+' || r == '~' || r == '-' || r == '@'
|
||||
isAllowed = isAllowed || unicode.IsLetter(r) || unicode.IsDigit(r) || unicode.IsMark(r)
|
||||
isAllowed = isAllowed || (r == '%' && i+2 < len(source) && ishex(source[i+1]) && ishex(source[i+2]))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue