Fixes empty pages from routing as home (/)

This commit is contained in:
Sam Georges 2014-07-23 08:35:53 +10:00
parent 4979f0fae4
commit bbbe11c174
1 changed files with 5 additions and 1 deletions

View File

@ -205,8 +205,12 @@ class Router
*/
$pages = $this->theme->listPages();
$map = [];
foreach ($pages as $page)
foreach ($pages as $page) {
if (!$page->url)
continue;
$map[] = ['file' => $page->getFileName(), 'pattern' => $page->url];
}
self::$urlMap = $map;
if ($cacheable)