diff --git a/_layouts/post.html b/_layouts/post.html index c4c3399..eb5a57f 100644 --- a/_layouts/post.html +++ b/_layouts/post.html @@ -2,38 +2,33 @@ layout: default --- -{% if page.banner-image %} - {% assign banner-pic = site.data.virtual-photography[page.slug][page.banner-image] %} -{% else %} - {% assign banner-pic = site.data.virtual-photography[page.slug][page.card-image] %} -{% endif %} - -{% assign ar = banner-pic.aspect-ratio | plus: 0 %} +{% assign banner_pic = page.banner-image | default: page.card-image %} +{% assign banner_data = site.data.virtual-photography[page.slug][banner_pic] %} +{% assign ar = banner_data.aspect-ratio | plus: 0 %}