mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 05:09:23 +01:00
parent
fcbf9e0ae5
commit
06b5e04b0b
@ -221,8 +221,12 @@ class Unix(callbacks.Plugin):
|
|||||||
'not available.'), Raise=True)
|
'not available.'), Raise=True)
|
||||||
(out, err) = inst.communicate()
|
(out, err) = inst.communicate()
|
||||||
inst.wait()
|
inst.wait()
|
||||||
lines = out.splitlines()
|
if sys.version_info[0] > 2:
|
||||||
lines = list(map(str.rstrip, lines))
|
lines = [i.decode('utf-8').rstrip() for i in out.splitlines()]
|
||||||
|
lines = list(map(str, lines))
|
||||||
|
else:
|
||||||
|
lines = out.splitlines()
|
||||||
|
lines = list(map(str.rstrip, lines))
|
||||||
lines = filter(None, lines)
|
lines = filter(None, lines)
|
||||||
irc.replies(lines, joiner=' ')
|
irc.replies(lines, joiner=' ')
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user