Commit c4bdeb40 authored by Jérôme Charaoui's avatar Jérôme Charaoui 🕯️
Browse files

Fix build errors with only 1 page of press articles

The pagination macro seems to assume there is >1 page of items but when
doing a partial build there may only be one. This skips rendering
pagination altogether when it's not needed.
parent d08644ab
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -49,7 +49,9 @@
  <tbody>
    {% from "macros/pagination.html" import render_pagination %}
    {% from "macros/press.html" import render_snippet %}
    {% if this.pagination.pages > 1 %}
    {{ render_pagination(this.pagination) }}
    {% endif %}
    {% for item in this.pagination.items %}
      {{ render_snippet(item, this.alt) }}
    {% endfor %}