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/)
This commit is contained in:
Christian Oliff
2025-02-26 17:27:31 +09:00
committed by GitHub
parent 1a4851f138
commit 2f4e666d7e
2 changed files with 2 additions and 2 deletions

View File

@@ -239,6 +239,6 @@
</div>
</blockquote>
{{- if not .pc.Simple -}}
<script async src="//www.instagram.com/embed.js"></script>
<script async src="https://www.instagram.com/embed.js"></script>
{{- end -}}
{{- end -}}

View File

@@ -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")