mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-08 22:43:31 +02:00
FB2 Output: Fix bug where <empty-line/> elements were put inside <p> tags.
This commit is contained in:
parent
b58cd26fa1
commit
6d0739ed1a
1 changed files with 1 additions and 1 deletions
|
|
@ -72,7 +72,7 @@ def fb2mlize_spine(self):
|
|||
|
||||
def clean_text(self, text):
|
||||
# Condense empty paragraphs into a line break.
|
||||
text = re.sub(r'(?miu)(<p>\s*</p>\s*){3,}', '<p><empty-line /></p>', text)
|
||||
text = re.sub(r'(?miu)(<p>\s*</p>\s*){3,}', '<empty-line />', text)
|
||||
# Remove empty paragraphs.
|
||||
text = re.sub(r'(?miu)<p>\s*</p>', '', text)
|
||||
# Clean up pargraph endings.
|
||||
|
|
|
|||
Loading…
Reference in a new issue