diff options
author | Joel Rosdahl <joel@rosdahl.net> | 2017-05-22 21:52:08 +0200 |
---|---|---|
committer | Joel Rosdahl <joel@rosdahl.net> | 2017-05-22 21:55:28 +0200 |
commit | cfad9dd366420682119d32e6f250fe203ad792f8 (patch) | |
tree | 47c9498e75f0fa0369df6dbb0eaa7a9282672762 /miniircd | |
parent | dac09f33c7edcc30cb0a2c264d218735fcd59e66 (diff) | |
download | miniircd-cfad9dd366420682119d32e6f250fe203ad792f8.tar.gz miniircd-cfad9dd366420682119d32e6f250fe203ad792f8.zip |
Simplify
The default encoding for str.encode and .decode is "utf-8".
Diffstat (limited to 'miniircd')
-rwxr-xr-x | miniircd | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -40,10 +40,10 @@ PY3 = sys.version_info[0] >= 3 if PY3: def buffer_to_socket(msg): - return msg.encode('utf-8') + return msg.encode() def socket_to_buffer(buf): - return buf.decode('utf-8') + return buf.decode() else: def buffer_to_socket(msg): return msg |