From 46ce56c58050a65d676c4e17b5ca348ea1409168 Mon Sep 17 00:00:00 2001 From: Jake Bailey Date: Mon, 11 Jan 2016 16:24:01 -0600 Subject: [PATCH] don't add spaces and instead make message optional, let the user decide --- client/commands.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/commands.go b/client/commands.go index e76fe53..e49faca 100644 --- a/client/commands.go +++ b/client/commands.go @@ -293,10 +293,10 @@ func (conn *Conn) Pong(message string) { conn.Raw(PONG + " :" + message) } // Cap sends a CAP command to the server. // CAP capability -func (conn *Conn) Cap(subcommmand string, messages ...string) { - if len(messages) == 0 { +func (conn *Conn) Cap(subcommmand string, message ...string) { + if len(message) == 0 { conn.Raw(CAP + " " + subcommmand) } else { - conn.Raw(CAP + " " + subcommmand + " :" + strings.Join(messages, " ")) + conn.Raw(CAP + " " + subcommmand + " :" + message[0]) } }