Strip text before adding blockquote markers (#76)

This commit is contained in:
André van Delft
2024-03-26 21:07:28 +01:00
committed by GitHub
parent 96a25cfbf3
commit 2f9a42d3b8
2 changed files with 8 additions and 2 deletions

View File

@@ -237,7 +237,7 @@ class MarkdownConverter(object):
if convert_as_inline:
return text
return '\n' + (line_beginning_re.sub('> ', text) + '\n\n') if text else ''
return '\n' + (line_beginning_re.sub('> ', text.strip()) + '\n\n') if text else ''
def convert_br(self, el, text, convert_as_inline):
if convert_as_inline: