diff --git a/core/scrapertools.py b/core/scrapertools.py index 06f7c6e5..5b6d4bac 100644 --- a/core/scrapertools.py +++ b/core/scrapertools.py @@ -41,7 +41,7 @@ def find_multiple_matches_groups(text, pattern): def decodeHtmlentities(data): import HTMLParser parser = HTMLParser.HTMLParser() - return parser.unescape(data).encode('utf-8') + return parser.unescape(data) def unescape(text): diff --git a/core/support.py b/core/support.py index 53d58836..0484ceb9 100755 --- a/core/support.py +++ b/core/support.py @@ -168,7 +168,7 @@ def scrapeLang(scraped, lang, longtitle): return language, longtitle def cleantitle(title): - cleantitle = scrapertools.htmlclean(scrapertools.decodeHtmlentities(title).replace('"', "'").replace('×', 'x').replace('–', '-')).strip() + cleantitle = scrapertools.htmlclean(scrapertools.decodeHtmlentities(title).replace('"', "'").replace(u'×', 'x').replace('–', '-')).strip() return cleantitle def scrapeBlock(item, args, block, patron, headers, action, pagination, debug, typeContentDict, typeActionDict, blacklist, search, pag, function, lang):