lib/pagy/extras/semantic.rb in pagy-5.0.0 vs lib/pagy/extras/semantic.rb in pagy-5.0.1

- old
+ new

@@ -15,9 +15,10 @@ pagy.series.each do |item| # series example: [1, :gap, 7, 8, "9", 10, 11, :gap, 36] html << case item when Integer then link.call item # page link when String then %(<a class="item active">#{item}</a>) # current page when :gap then %(<div class="disabled item">#{pagy_t 'pagy.nav.gap'}</div>) # page gap + else raise InternalError, "expected item types in series to be Integer, String or :gap; got #{item.inspect}" end end html << pagy_semantic_next_html(pagy, link) html << %(</div>) end