Fix @String decode utf8 issue

This commit is contained in:
Valentin Lorentz 2011-01-26 08:30:20 +01:00
parent 17248b5d2c
commit 1cceeb7ad1

View File

@ -85,7 +85,7 @@ class String(callbacks.Plugin):
<http://docs.python.org/library/codecs.html#standard-encodings>. <http://docs.python.org/library/codecs.html#standard-encodings>.
""" """
try: try:
irc.reply(text.decode(encoding).encode('utf-8')) irc.reply(text.decode(encoding))
except LookupError: except LookupError:
irc.errorInvalid(_('encoding'), encoding) irc.errorInvalid(_('encoding'), encoding)
except binascii.Error: except binascii.Error: