diff options
author | Benny Morrison <benmorrison@ttm.sh> | 2019-03-17 20:58:25 -0400 |
---|---|---|
committer | Benny Morrison <benmorrison@ttm.sh> | 2019-03-17 20:58:25 -0400 |
commit | aba376610ed0a9ac725991b40c9c8b060d0a5be3 (patch) | |
tree | b110a6fb0d005d1b2ffe6a573636b51f3fece536 /main.go | |
parent | 90612aa253e70ce4331523bad0caee3e9fa953ed (diff) | |
download | goofbot-aba376610ed0a9ac725991b40c9c8b060d0a5be3.tar.gz |
updated !users to not ping in irc
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/main.go b/main.go index a61c764..0c59272 100644 --- a/main.go +++ b/main.go @@ -139,7 +139,15 @@ func main() { if err != nil { log.Fatalln("Error while running 'who -q'") } - c.Cmd.Reply(e, out.String()) + userlist := strings.Split(out.String(), " ") + var sanilist string + for i, e := range userlist { + userlist[i] = "~" + e + } + for i := range userlist { + sanilist += userlist[i] + } + c.Cmd.Reply(e, sanilist[:9]) return } // number of total human users on the server |