fix: class name in render-data

This commit is contained in:
Xin
2024-04-30 23:54:06 +01:00
parent 0da6f97e99
commit 2004648076
2 changed files with 4 additions and 4 deletions

View File

@ -5,14 +5,14 @@
*/}}
{{ $data := "" }}
{{ $section := .Section | default "" }}
{{ $sidebarKey := "sidebar" }}
{{ $filename := "sidebar" }}
{{ if hugo.IsMultilingual }}
{{ with (index site.Data site.Language.Lang $sidebarKey $section) }}
{{ with (index site.Data site.Language.Lang $filename $section) }}
{{ $data = . }}
{{ end }}
{{ else }}
{{ with (index site.Data $sidebarKey $section) }}
{{ with (index site.Data $filename $section) }}
{{ $data = . }}
{{ end }}
{{ end }}