mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-04 02:45:50 +02:00
Forgot to also catch attributeerror for people running from source
This commit is contained in:
parent
78d048c809
commit
1c82942ed8
1 changed files with 1 additions and 1 deletions
|
|
@ -761,7 +761,7 @@ def html_as_json(root):
|
|||
ensure_body(root)
|
||||
try:
|
||||
serialize = plugins['html_as_json'][0].serialize
|
||||
except KeyError:
|
||||
except (KeyError, AttributeError):
|
||||
return as_bytes(json.dumps(html_as_dict(root), ensure_ascii=False, separators=(',', ':')))
|
||||
for child in tuple(root.iterchildren('*')):
|
||||
if child.tag.partition('}')[-1] not in ('head', 'body'):
|
||||
|
|
|
|||
Loading…
Reference in a new issue