这可能是 Jekyll 中的错误吗? ('endfor' 未知标签)

Can this be a Bug in Jekyll? ('endfor' unknown tag)

今天刚开始使用 Jekyll,我遇到了麻烦...这是我的错误消息:

Unknown tag 'endfor' in _includes/masonry.html

我看不出错误的原因。请帮我! 这是 jekyll 认为错误的代码:

<div class="gallery masonry-gallery no-margin">
    {% for item in page.slideshow %}
                            <figure class="gallery-item">
                                <header class='gallery-icon'>
                                    <a href="{% if item.image_small %}{{ item.image_small }}{{ endif }}" class="popup"><img src="{{ item.image }}" alt="" /></a>
                                </header>   
                                <figcaption class='gallery-caption'>
                                    <div class="entry-summary">
                                        <h3>{% if item.caption %}{{ item.caption }}{% endif %}</h3>
                                        <p>{% if item.description %}{{ item.description }}{% endif %}</p>
                                    </div>
                                </figcaption>
                            </figure>

    {% endfor %}

有趣的是,当我取出 for 循环时,我得到了这个:

Liquid syntax error: 'if' tag was never closed

对我来说完全没有意义...请帮助我!!!

提前致谢, 最大值

<a href="{% if item.image_small %}{{ item.image_small }}{{ endif }}" class="popup"><img src="{{ item.image }}" alt="" /></a>

应该是

<a href="{% if item.image_small %}{{ item.image_small }}{% endif %}" class="popup"><img src="{{ item.image }}" alt="" /></a>