diff --git a/src/renderer/html_handlebars/helpers/toc.rs b/src/renderer/html_handlebars/helpers/toc.rs index 7ecb4da6..7164a222 100644 --- a/src/renderer/html_handlebars/helpers/toc.rs +++ b/src/renderer/html_handlebars/helpers/toc.rs @@ -39,14 +39,17 @@ impl HelperDef for RenderToc { }; if level > current_level { - try!(rc.writer.write("
  • ".as_bytes())); - try!(rc.writer.write("".as_bytes())); + try!(rc.writer.write("
  • ".as_bytes())); + current_level -= 1; } try!(rc.writer.write("".as_bytes()));