From 2f4e666d7e029cba176f0adae1fbe4f813a5d1de Mon Sep 17 00:00:00 2001 From: Christian Oliff Date: Wed, 26 Feb 2025 17:27:31 +0900 Subject: [PATCH] tpl: HTTPS the instagram Shortcode JS This JavaScript will always load over HTTPS so it's best to specify that. Protocol-less loaded resources are an anti-pattern (REF: https://www.paulirish.com/2010/the-protocol-relative-url/) --- tpl/tplimpl/embedded/templates/shortcodes/instagram.html | 2 +- tpl/tplimpl/shortcodes_integration_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tpl/tplimpl/embedded/templates/shortcodes/instagram.html b/tpl/tplimpl/embedded/templates/shortcodes/instagram.html index 5d940d67b..17188c6fd 100644 --- a/tpl/tplimpl/embedded/templates/shortcodes/instagram.html +++ b/tpl/tplimpl/embedded/templates/shortcodes/instagram.html @@ -239,6 +239,6 @@ {{- if not .pc.Simple -}} - + {{- end -}} {{- end -}} diff --git a/tpl/tplimpl/shortcodes_integration_test.go b/tpl/tplimpl/shortcodes_integration_test.go index b8a4ad833..d669bb333 100644 --- a/tpl/tplimpl/shortcodes_integration_test.go +++ b/tpl/tplimpl/shortcodes_integration_test.go @@ -256,7 +256,7 @@ Content: {{ .Content }} // Regular mode b := hugolib.Test(t, files) - b.AssertFileContent("public/index.html", "a7937c49665872d3") + b.AssertFileContent("public/index.html", "6e93404b93277876") // Simple mode files = strings.ReplaceAll(files, "privacy.instagram.simple = false", "privacy.instagram.simple = true")