mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-19 08: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:
|
||||
resp.append('%s: %s' % self._bold(m.groups()))
|
||||
if resp:
|
||||
resp = map(utils.htmlToText, resp)
|
||||
irc.reply('; '.join(resp), prefixName = False)
|
||||
aspnRecipes = urlSnarfer(aspnRecipes)
|
||||
|
||||
|
@ -64,6 +64,9 @@ class PythonTestCase(PluginTestCase, PluginDocumentation):
|
||||
'http://aspn.activestate.com/ASPN/Cookbook/Python/'
|
||||
'Recipe/230113',
|
||||
'Implementation of sets using sorted lists')
|
||||
self.assertNotRegexp('http://aspn.activestate.com/ASPN/'
|
||||
'Cookbook/Python/Recipe/144183',
|
||||
'\n')
|
||||
finally:
|
||||
conf.supybot.plugins.Python.aspnSnarfer.setValue(False)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user