From 9903d276ef3a6148792f39a94a09fb147ef19fb3 Mon Sep 17 00:00:00 2001 From: sarahec Date: Fri, 12 Jan 2024 15:01:01 -0800 Subject: [PATCH] Use builtin function to detect production --- layouts/partials/head.html | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/layouts/partials/head.html b/layouts/partials/head.html index fcf19979..b53aa672 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -3,8 +3,7 @@ {{ hugo.Generator }} -{{/* NOTE: For Production make sure you add `HUGO_ENV="production"` before your build command */}} -{{ if eq (getenv "HUGO_ENV") "production" | or (eq .Site.Params.env "production") }} +{{ if hugo.IsProduction }} {{ else }}