mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-26 20:59:27 +01:00
Make sure we utils.htmlToText the aspnSnarfer, otherwise we can get nasty
replies because of the embedded \n.
This commit is contained in:
parent
f31fec5681
commit
d85e56f1d2
@ -192,6 +192,7 @@ class Python(callbacks.PrivmsgCommandAndRegexp):
|
|||||||
if m:
|
if m:
|
||||||
resp.append('%s: %s' % self._bold(m.groups()))
|
resp.append('%s: %s' % self._bold(m.groups()))
|
||||||
if resp:
|
if resp:
|
||||||
|
resp = map(utils.htmlToText, resp)
|
||||||
irc.reply('; '.join(resp), prefixName = False)
|
irc.reply('; '.join(resp), prefixName = False)
|
||||||
aspnRecipes = urlSnarfer(aspnRecipes)
|
aspnRecipes = urlSnarfer(aspnRecipes)
|
||||||
|
|
||||||
|
@ -64,6 +64,9 @@ class PythonTestCase(PluginTestCase, PluginDocumentation):
|
|||||||
'http://aspn.activestate.com/ASPN/Cookbook/Python/'
|
'http://aspn.activestate.com/ASPN/Cookbook/Python/'
|
||||||
'Recipe/230113',
|
'Recipe/230113',
|
||||||
'Implementation of sets using sorted lists')
|
'Implementation of sets using sorted lists')
|
||||||
|
self.assertNotRegexp('http://aspn.activestate.com/ASPN/'
|
||||||
|
'Cookbook/Python/Recipe/144183',
|
||||||
|
'\n')
|
||||||
finally:
|
finally:
|
||||||
conf.supybot.plugins.Python.aspnSnarfer.setValue(False)
|
conf.supybot.plugins.Python.aspnSnarfer.setValue(False)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user