SpiffyTitles: fixes #34 - can't find title on some websites
This commit is contained in:
parent
cae4038fdd
commit
35f71d7a57
|
|
@ -518,7 +518,7 @@ class SpiffyTitles(callbacks.Plugin):
|
|||
|
||||
if soup is not None:
|
||||
# TODO: What should happen if there is more than one <title> tag?
|
||||
title = head.find("title")
|
||||
title = soup.find("title")
|
||||
|
||||
if title is not None:
|
||||
title_text = title.get_text()
|
||||
|
|
@ -539,8 +539,7 @@ class SpiffyTitles(callbacks.Plugin):
|
|||
|
||||
headers = {
|
||||
"User-Agent": agent,
|
||||
"Accept-Language": ";".join((self.accept_language, "q=1.0")),
|
||||
"Accept": "text/html;q=1.0"
|
||||
"Accept-Language": ";".join((self.accept_language, "q=1.0"))
|
||||
}
|
||||
|
||||
self.log.info("SpiffyTitles: requesting %s" % (url))
|
||||
|
|
|
|||
Loading…
Reference in New Issue