forked from khuxkm/cosmicbot
Hopefully fix incorrect roster command output
This commit is contained in:
parent
a61b7808e1
commit
4b2b2a1157
2
bot.py
2
bot.py
|
@ -54,7 +54,7 @@ class CosmicBot(teambot.Handler):
|
|||
output = subprocess.check_output(["/usr/local/bin/roster",namecnt]).decode("ascii").split("\n")
|
||||
output = filter(None,output)
|
||||
for line in output:
|
||||
line = re.sub("\s+"," ",line).split()
|
||||
line = re.sub("\s+"," ",line).split(" ",1)
|
||||
self.say(channel,"{}: {} (by {})".format(nick,line[1],unhighlight_nick(line[0])))
|
||||
|
||||
if __name__=="__main__":
|
||||
|
|
Loading…
Reference in New Issue