From fe49f96267dfc3cbf2e41d97e63c0b09a37b9136 Mon Sep 17 00:00:00 2001 From: Emanuele Bardelli Date: Thu, 19 Nov 2020 06:45:12 -0500 Subject: [PATCH] fix: add definition for $show_organizations to People widget Commit 97606bf added support for show_organizations in the people widget. The original author forgot to add the definition of this variable at top of the widget, leading to hugo not being able to build the site because the variable was not initialized. This commit adds a definition for show_organizations at the top of the widget and fixes the build error. Fix 97606bf --- wowchemy/layouts/partials/widgets/people.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wowchemy/layouts/partials/widgets/people.html b/wowchemy/layouts/partials/widgets/people.html index a360fc72..a4b8737b 100644 --- a/wowchemy/layouts/partials/widgets/people.html +++ b/wowchemy/layouts/partials/widgets/people.html @@ -5,6 +5,7 @@ {{ $page := .page }} {{ $show_social := $page.Params.design.show_social | default false }} {{ $show_interests := $page.Params.design.show_interests | default true }} +{{ $show_organizations := $page.Params.design.show_organizations | default false }}
{{ with $page.Title }} @@ -51,7 +52,7 @@

{{with $link}}{{end}}{{ .Title }}{{if $link}}{{end}}

- {{ if and $show_organizations .Params.organizations }}{{range .Params.organizations }}

{{ .name | markdownify | emojify }}

{{ end }}{{ end }} + {{ if and $show_organizations .Params.organizations }}{{ range .Params.organizations }}

{{ .name }}

{{ end }}{{ end }} {{ with .Params.role }}

{{ . | markdownify | emojify }}

{{ end }} {{ if $show_social }}{{ partial "social_links" . }}{{ end }} {{ if and $show_interests .Params.interests }}

{{ delimit .Params.interests ", " | markdownify | emojify }}

{{ end }}