Fail if no content for gallery
This commit is contained in:
@@ -12,6 +12,10 @@
|
|||||||
{{ $inner := chomp .Inner }}
|
{{ $inner := chomp .Inner }}
|
||||||
{{ $resources := slice }}
|
{{ $resources := slice }}
|
||||||
|
|
||||||
|
{{ if and (not $images) (not $inner) }}
|
||||||
|
{{ errorf "paige/gallery: no content specified" }}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
{{ if not $inner }}
|
{{ if not $inner }}
|
||||||
{{ with $images }}
|
{{ with $images }}
|
||||||
{{ with $.Page.Resources.Match . }}
|
{{ with $.Page.Resources.Match . }}
|
||||||
|
Reference in New Issue
Block a user