From 957b2f1da8a1d3f30d2c56a0917cb836eec2855c Mon Sep 17 00:00:00 2001 From: Tim Bannister Date: Mon, 29 Jun 2020 18:54:30 +0100 Subject: [PATCH] Warn on use of capture shortcode If anyone uses the capture shortcode, emit a warning. The website no longer uses capture shortcodes. --- layouts/shortcodes/capture.html | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/layouts/shortcodes/capture.html b/layouts/shortcodes/capture.html index 6cb2e5a9c9937..81b996034a83b 100644 --- a/layouts/shortcodes/capture.html +++ b/layouts/shortcodes/capture.html @@ -1,7 +1 @@ -{{ $_hugo_config := `{ "version": 1 }`}} -{{- $id := .Get 0 -}} -{{- if not $id -}} -{{- errorf "missing id in capture" -}} -{{- end -}} -{{- $capture_id := printf "__cid_%s" $id -}} -{{- .Page.Scratch.Set $capture_id .Inner -}} \ No newline at end of file +{{ warnf "Invalid shortcode in %q" .Page.Path }} \ No newline at end of file