aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--utils.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/utils.go b/utils.go
index 81c2f70..e09456e 100644
--- a/utils.go
+++ b/utils.go
@@ -3,7 +3,7 @@ package main
import "github.com/lrstanley/girc"
func IrcJoin(irc *girc.Client, channel []string) {
- if len(channel) >= 0 && channel[0] == "" {
+ if len(channel) > 1 && channel[1] != "" {
irc.Cmd.JoinKey(channel[0], channel[1])
} else {
irc.Cmd.Join(channel[0])