fix: fix broken Edit Page links (#339)

This commit is contained in:
Andreas Deininger 2022-02-13 22:48:38 +01:00 committed by GitHub
parent b57817fb3a
commit f66ca6a07d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

3
.gitignore vendored
View File

@ -21,5 +21,8 @@ exampleSite/content/de
/exampleSite/resources/
/exampleSite/data/sprites/
# hugo
.hugo_build.lock
# testing
.lighthouseci/

View File

@ -1,7 +1,7 @@
{{ $geekdocRepo := default (default false .Site.Params.GeekdocRepo) .Page.Params.GeekdocRepo }}
{{ $geekdocEditPath := default (default false .Site.Params.GeekdocEditPath) .Page.Params.GeekdocEditPath }}
{{ if .File }}
{{ $.Scratch.Set "geekdocFilePath" (default .File.Path .Page.Params.GeekdocFilePath) }}
{{ $.Scratch.Set "geekdocFilePath" (default (path.Join .File.Lang .File.Path) .Page.Params.GeekdocFilePath) }}
{{ else }}
{{ $.Scratch.Set "geekdocFilePath" false }}
{{ end }}