Use path.Join to construct hugo links (#92)
Use path.Join so that it will render correctly on Windows (path.Join will convert Windows backslash to forward slash)
This commit is contained in:
parent
9bce284697
commit
c5ba5b7aef
@ -217,7 +217,7 @@ And `layouts/_default/_markup/render-image.html` for images:
|
||||
{{- if strings.HasSuffix $url.Path ".md" -}}
|
||||
{{- relref .Page .Destination | safeURL -}}
|
||||
{{- else -}}
|
||||
{{- printf "/%s%s" .Page.File.Dir .Destination | safeURL -}}
|
||||
{{- path.Join "/" .Page.File.Dir .Destination | safeURL -}}
|
||||
{{- end -}}
|
||||
{{- else -}}
|
||||
{{- .Destination | safeURL -}}
|
||||
|
Loading…
Reference in New Issue
Block a user