decode html

This commit is contained in:
j 2016-01-08 16:14:18 +05:30
parent 71d8825783
commit 5d02474ce8

View file

@ -15,6 +15,8 @@ from . import epub
from . import txt
from . import opf
from meta.utils import decode_html_data
def get_id(f=None, data=None):
if data:
return base64.b32encode(hashlib.sha1(data).digest()).decode()
@ -83,5 +85,6 @@ def metadata(f, from_=None):
data['title'] = data['title'][:-len(postfix)]
if not data['title'].strip():
del data['title']
data = decode_html_data(data)
return data