Prefer existing and translated variant of home page (#342)

* Prefer existing and translated variant of home page as the site link in the menu header.
* More compact "cond"-version of fix.
feature/prev-next
Nikolay Raspopov 2021-05-20 23:02:31 +03:00 committed by GitHub
parent 553d378db3
commit 345cb5d947
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -1,5 +1,5 @@
<h2 class="book-brand">
<a href="{{ .Site.BaseURL | relLangURL }}">
<a href="{{ cond (not .Site.Home.File) .Sites.First.Home.RelPermalink .Site.Home.RelPermalink }}">
{{- with .Site.Params.BookLogo -}}
<img src="{{ . | relURL }}" alt="Logo" />
{{- end -}}