mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-11 12:42:34 +01:00
Undo the web title fix because it appears it broke more than it fixed.
This commit is contained in:
parent
b533290c7a
commit
f3e5223f3f
@ -90,10 +90,6 @@ class Web(callbacks.PluginRegexp):
|
|||||||
try:
|
try:
|
||||||
size = conf.supybot.protocols.http.peekSize()
|
size = conf.supybot.protocols.http.peekSize()
|
||||||
text = utils.web.getUrl(url, size=size)
|
text = utils.web.getUrl(url, size=size)
|
||||||
try:
|
|
||||||
text = text.decode('utf8')
|
|
||||||
except UnicodeDecodeError:
|
|
||||||
text = text.decode('latin1')
|
|
||||||
except utils.web.Error, e:
|
except utils.web.Error, e:
|
||||||
self.log.info('Couldn\'t snarf title of %u: %s.', url, e)
|
self.log.info('Couldn\'t snarf title of %u: %s.', url, e)
|
||||||
return
|
return
|
||||||
@ -174,10 +170,6 @@ class Web(callbacks.PluginRegexp):
|
|||||||
"""
|
"""
|
||||||
size = conf.supybot.protocols.http.peekSize()
|
size = conf.supybot.protocols.http.peekSize()
|
||||||
text = utils.web.getUrl(url, size=size)
|
text = utils.web.getUrl(url, size=size)
|
||||||
try:
|
|
||||||
text = text.decode('utf8')
|
|
||||||
except UnicodeDecodeError:
|
|
||||||
text = text.decode('latin1')
|
|
||||||
parser = Title()
|
parser = Title()
|
||||||
try:
|
try:
|
||||||
parser.feed(text)
|
parser.feed(text)
|
||||||
|
Loading…
Reference in New Issue
Block a user