Do not populate prev/next on section index rendering

This commit is contained in:
Vincent Prouillet 2017-05-01 17:31:51 +09:00
parent 177826a110
commit fc960c1771
2 changed files with 2 additions and 2 deletions

View file

@ -106,7 +106,7 @@ along with it that are NOT markdown.
Those assets will be copied in the same folder when building so you can just use a relative path to use them.
A summary is only defined if you put `<!-- more -->` in the content. If present in a page, the summary will be from
the start up to that tag.s
the start up to that tag.
### Sections
Sections represent a group of pages, for example a `tutorials` section of your site.

View file

@ -202,7 +202,7 @@ impl Site {
for (parent_path, section) in &mut self.sections {
// TODO: avoid this clone
let (sorted_pages, _) = sort_pages(section.pages.clone(), Some(&section));
section.pages = populate_previous_and_next_pages(sorted_pages.as_slice());
section.pages = sorted_pages;
match grandparent_paths.get(parent_path) {
Some(paths) => section.subsections.extend(paths.clone()),