pull/137/merge
Raphaël Cohen 4 years ago committed by GitHub
commit 38629cd9d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -134,7 +134,9 @@ def get_body(doc):
elem.drop_tree()
# tostring() always return utf-8 encoded string
# FIXME: isn't better to use tounicode?
raw_html = str_(tostring(doc.body or doc))
raw_html = tostring(doc.body or doc)
if isinstance(raw_html, bytes):
raw_html = raw_html.decode()
cleaned = clean_attributes(raw_html)
try:
# BeautifulSoup(cleaned) #FIXME do we really need to try loading it?

Loading…
Cancel
Save