From 3eb343c53a13af92369c34eb34508e4d25483a87 Mon Sep 17 00:00:00 2001 From: radude Date: Wed, 18 Jul 2018 08:17:02 +0000 Subject: [PATCH] fixed ol lists with empty lines between items --- mdx_truly_sane_lists/mdx_truly_sane_lists.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mdx_truly_sane_lists/mdx_truly_sane_lists.py b/mdx_truly_sane_lists/mdx_truly_sane_lists.py index 5af6370..2f66625 100644 --- a/mdx_truly_sane_lists/mdx_truly_sane_lists.py +++ b/mdx_truly_sane_lists/mdx_truly_sane_lists.py @@ -58,7 +58,7 @@ def run(self, parent, blocks): items = self.get_items(blocks.pop(0)) sibling = self.lastChild(parent) - if not self.truly_sane and (sibling is not None and sibling.tag in self.SIBLING_TAGS): + if (sibling is not None and sibling.tag in self.SIBLING_TAGS) and (sibling.tag == 'ol' or not self.truly_sane): lst = sibling if lst[-1].text: p = util.etree.Element('p')