hugo-toha/layouts/partials/helpers/get-author-name.html
Cristian Marquez Russo bce35a80e1
Update get-author-name.html
Changed default to the parameters in Config file for consistency
2020-08-09 16:15:41 +12:00

12 lines
347 B
HTML

{{ $authorName:= .Site.Params.author.name }}
{{ if .Site.Data.site.author}}
{{ $authorName = .Site.Data.site.author.name }}
{{ end}}
{{ if eq (printf "%T" .Params.author ) "maps.Params" }}
{{ with .Params.author }}
{{ if .name }}
{{ $authorName = .name }}
{{ end }}
{{ end }}
{{ end }}
{{ return $authorName }}