mirror of
https://github.com/tiennm99/HugoBlox-kit.git
synced 2026-10-13 04:14:41 +00:00
fix: 1c09422 error calling isset
error calling isset: calling IsSet with unsupported type "invalid" (<nil>) will always return false See https://github.com/wowchemy/wowchemy-hugo-themes/commit/1c094227ecea2f534321f80c6113522b234e5012#commitcomment-123412561
This commit is contained in:
1 parent
1c094227ec
commit
2342b0c39a
1 file changed
+3
-3
@@ -151,13 +151,13 @@
|
||||
{{ $use_headroom := not (.IsHome | or (eq .Type "book")) }}
|
||||
|
||||
{{/* Check for the global site parameter `header.on_scroll` */}}
|
||||
{{ if (isset site.Params.header "on_scroll") }}
|
||||
{{ if site.Params.header.on_scroll }}
|
||||
{{ $use_headroom = eq site.Params.header.on_scroll "disappear" }}
|
||||
{{ end }}
|
||||
|
||||
{{/* Check for the page parameter `header.on_scroll` */}}
|
||||
{{ if (isset $.Params.header "on_scroll") }}
|
||||
{{ $use_headroom = eq $.Params.header.on_scroll "disappear" }}
|
||||
{{ if .Params.header.on_scroll }}
|
||||
{{ $use_headroom = eq .Params.header.on_scroll "disappear" }}
|
||||
{{ end }}
|
||||
|
||||
{{/* Output `use_headroom` variable for Headroom initialization in Wowchemy JS */}}
|
||||
|
||||
Reference in new issue
Block a user