From bc57bf8c8b2300403387962921b0aeaea33edbba Mon Sep 17 00:00:00 2001 From: marco Date: Mon, 20 Jan 2020 22:42:33 +0100 Subject: [PATCH] test --- core/scrapertools.py | 2 +- core/support.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) 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):