mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 05:09:23 +01:00
String: Trim trailing \n from encode's response.
Certain encode functions, like base64, add a trailing \n which simply clutters the response for Supybot. Signed-off-by: James Vega <jamessan@users.sourceforge.net>
This commit is contained in:
parent
6a0b667817
commit
804fbe8209
@ -66,7 +66,7 @@ class String(callbacks.Plugin):
|
||||
<http://docs.python.org/library/codecs.html#standard-encodings>.
|
||||
"""
|
||||
try:
|
||||
irc.reply(text.encode(encoding))
|
||||
irc.reply(text.encode(encoding).rstrip('\n'))
|
||||
except LookupError:
|
||||
irc.errorInvalid('encoding', encoding)
|
||||
encode = wrap(encode, ['something', 'text'])
|
||||
|
Loading…
Reference in New Issue
Block a user