mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-22 18:14:41 +01:00
RSS: Fall back to decoding the headline with 'utf8' if 'ascii' failed.
This commit is contained in:
parent
53c7c9beaa
commit
33a236079f
@ -155,10 +155,17 @@ class RSS(callbacks.Plugin):
|
||||
if self.registryValue(dateconfig, channel):
|
||||
if headline[2]:
|
||||
pubDate = ' [%s]' % (headline[2],)
|
||||
try:
|
||||
newheadlines.append(format('%s %u%s',
|
||||
headline[0],
|
||||
link,
|
||||
pubDate))
|
||||
except UnicodeDecodeError:
|
||||
newheadlines.append(format('%s %u%s',
|
||||
headline[0].decode('utf8',
|
||||
'replace'),
|
||||
link,
|
||||
pubDate))
|
||||
return newheadlines
|
||||
|
||||
def _newHeadlines(self, irc, channels, name, url):
|
||||
|
Loading…
Reference in New Issue
Block a user