Skip to content

Commit

Permalink
Warn on use of capture shortcode
Browse files Browse the repository at this point in the history
If anyone uses the capture shortcode, emit a warning. The website
no longer uses capture shortcodes.
  • Loading branch information
sftim committed Jun 29, 2020
1 parent 30b8110 commit 957b2f1
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions layouts/shortcodes/capture.html
Original file line number Diff line number Diff line change
@@ -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 -}}
{{ warnf "Invalid shortcode in %q" .Page.Path }}

0 comments on commit 957b2f1

Please sign in to comment.