8
0
Fork 0

Fix first page calculation

Dieser Commit ist enthalten in:
Stéphane Goetz 2015-04-27 16:47:14 +02:00 committet von Stéphane Goetz
Ursprung 3e374c7585
Commit d01374dddb
1 geänderte Dateien mit 6 neuen und 1 gelöschten Zeilen

Datei anzeigen

@ -72,7 +72,12 @@ abstract class Entry
if ($this instanceof Directory) {
foreach ($this->value as $node) {
if ($node instanceof Content && $node->title != 'index') {
if ($node instanceof Content) {
if (!count($node->getParents()) && $node->title == 'index') {
//the homepage should not count as first page
continue;
}
$this->first_page = $node;
return $node;
}