The `<li>` needs to be added to `toks` regardless of the value of `type` since formats the nested list.