cleanup_outline

in resources/asciidoctor/lib/chunker/convert_outline.rb [16:25]


    def cleanup_outline(outline, node, toclevels)
      node.sections.each do |section|
        next if section.roles.include? 'exclude'

        outline.gsub!(%(href="##{section.id}"), %(href="#{section.id}.html")) ||
          raise("Couldn't fix section link for #{section.id} in #{outline}")
        cleanup_outline outline, section, toclevels if section.level < toclevels
      end
    end