diff options
Diffstat (limited to 'markdown/preprocessors.py')
-rw-r--r-- | markdown/preprocessors.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/markdown/preprocessors.py b/markdown/preprocessors.py index 3751264..6238303 100644 --- a/markdown/preprocessors.py +++ b/markdown/preprocessors.py @@ -50,7 +50,7 @@ class NormalizeWhitespace(Preprocessor): source = source.replace(util.STX, "").replace(util.ETX, "") source = source.replace("\r\n", "\n").replace("\r", "\n") + "\n\n" source = source.expandtabs(self.markdown.tab_length) - source = re.sub(r'\n +\n', '\n\n', source) + source = re.sub(r'(?<=\n) +\n', '\n', source) return source.split('\n') |