Этот коммит содержится в:
Casey McLaughlin
2015-01-22 16:52:45 -05:00
родитель 5968cfef3e
Коммит 742bb52ff0
4 изменённых файлов: 94 добавлений и 65 удалений

Просмотреть файл

@@ -71,7 +71,7 @@ class TocGenerator
}
// Parse HTML
$tagsToMatch = $this->determineHeaderTags($topLevel, $depth);
$tagsToMatch = $this->determineHeaderTags($topLevel, $depth);
$parsed = $this->domParser->str_get_html($markup);
// Runtime exception for bad code
@@ -97,7 +97,7 @@ class TocGenerator
$level = array_search(strtolower($tagName), $tagsToMatch) + 1;
// Determine parent item which to add child
if ($level == 0) {
if ($level == 1) {
$parent = $menu;
}
elseif ($level == $lastElem->getLevel()) {