Fix gallery size bug

-  Improperly evaluated size of gallery arrays as strings and not integers
- Close #402
This commit is contained in:
Michael Rose 2016-07-20 16:05:31 -04:00
parent 9a9cbc01e3
commit 2d818cc8d1

View file

@ -6,11 +6,9 @@
{% assign gallery = page.gallery %}
{% endif %}
{% capture gallery_size %}{{ gallery | size }}{% endcapture %}
{% if gallery_size == '2' %}
{% if gallery.size == 2 %}
{% assign gallery_layout = 'half' %}
{% elsif gallery_size >= '3' %}
{% elsif gallery.size >= 3 %}
{% assign gallery_layout = 'third' %}
{% else %}
{% assign gallery_layout = '' %}