As we are couting the pages from 1 we have to continue until pages+1
This commit is contained in:
parent
d79d94277b
commit
a116eaf0ee
|
@ -252,8 +252,9 @@ module Jekyll
|
|||
all_posts = self.posts.sort { |a,b| b <=> a }
|
||||
|
||||
pages = Pager.calculate_pages(all_posts, self.config['paginate'].to_i)
|
||||
|
||||
pages += 1
|
||||
(1..pages).each do |num_page|
|
||||
|
||||
pager = Pager.new(self.config, num_page, all_posts, pages)
|
||||
page = Page.new(self, self.source, dir, file)
|
||||
page.render(self.layouts, site_payload.merge({'paginator' => pager.to_hash}))
|
||||
|
|
Loading…
Reference in New Issue