Optionally split over "," instead of spaces.

master
Robert Gerus 2015-12-22 21:20:32 +01:00
parent 4eb280fad0
commit 21d3d48791
1 changed files with 6 additions and 1 deletions

View File

@ -13,7 +13,12 @@ import (
)
func pick(output func(irc.Message), msg irc.Message) {
args := strings.Split(msg.Trailing, " ")
var args []string
if strings.Contains(msg.Trailing, ",") {
args = strings.Split(msg.Trailing, ",")
} else {
args = strings.Split(msg.Trailing, " ")
}
if args[0] != ":pick" {
return
}