diff options
author | Hubert Hirtz <hubert@hirtz.pm> | 2021-05-20 15:14:08 +0200 |
---|---|---|
committer | Hubert Hirtz <hubert@hirtz.pm> | 2021-05-20 22:45:48 +0200 |
commit | 9e679e266060b18f2239a8c0b84dab29aefa8230 (patch) | |
tree | 855389f5ce12275060c9f6b9394971fb799e9370 /commands.go | |
parent | Separate command handling from plain messages (diff) |
Explicitly support keys in JOIN messages
Diffstat (limited to 'commands.go')
-rw-r--r-- | commands.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/commands.go b/commands.go index 437bf77..a0cd411 100644 --- a/commands.go +++ b/commands.go @@ -197,7 +197,11 @@ func commandDoHelp(app *App, buffer string, args []string) (err error) { } func commandDoJoin(app *App, buffer string, args []string) (err error) { - app.s.Join(args[0]) + key := "" + if len(args) == 2 { + key = args[1] + } + app.s.Join(args[0], key) return } |