Fix toc generator to skip list items with only text nodes

This commit is contained in:
kisenka 2015-02-27 19:21:29 +04:00
parent 9b32167f92
commit d33913f4bb

View File

@ -100,7 +100,8 @@ module Docs
pages = []
REXML::XPath.each(li_node, 'ul/li') do |li|
pages.push(extract_items(li))
subpages = extract_items(li)
pages.push(subpages) if subpages != nil
end
item['pages'] = pages unless pages.empty?