Skip to content
Snippets Groups Projects
Commit 35f784cc authored by Olivia206's avatar Olivia206
Browse files

other method for default image in partials

parent f915aece
No related branches found
No related tags found
No related merge requests found
......@@ -83,14 +83,15 @@
{{ end }}
</div>
<div class="media">
{{- if .Params.image -}}
{{- $event_image := cond (isset .Params "image") .Params.image ( and (.Site.Params.events.default_image) (site.Data.website.default_image)) -}}
{{- if $event_image -}}
{{- partial "commons/image.html"
(dict
"image" .Params.image
"image" $event_image
"sizes" site.Params.image_sizes.sections.events.item
) -}}
{{- else if site.Data.website.default_image -}}
{{- partial "commons/image-default.html" -}}
{{/* {{- else if site.Data.website.default_image -}}
{{- partial "commons/image-default.html" -}} */}}
{{- end -}}
</div>
</article>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment