1
0
mirror of https://github.com/gryf/ebook-converter.git synced 2026-04-22 06:01:32 +02:00

Removed superfluous lopen builtin

This commit is contained in:
2020-04-20 21:12:22 +02:00
parent 3ca3f08054
commit 9e076e0af4
38 changed files with 107 additions and 195 deletions
@@ -51,14 +51,14 @@ class MOBIInput(InputFormatPlugin):
if raw:
if isinstance(raw, str):
raw = raw.encode('utf-8')
with lopen('debug-raw.html', 'wb') as f:
with open('debug-raw.html', 'wb') as f:
f.write(raw)
from ebook_converter.ebooks.oeb.base import close_self_closing_tags
for f, root in parse_cache.items():
raw = html.tostring(root, encoding='utf-8', method='xml',
include_meta_content_type=False)
raw = close_self_closing_tags(raw)
with lopen(f, 'wb') as q:
with open(f, 'wb') as q:
q.write(raw)
accelerators['pagebreaks'] = '//h:div[@class="mbp_pagebreak"]'
return mr.created_opf_path