diff --git a/daemon.go b/daemon.go index d8cc3b8..30d458b 100644 --- a/daemon.go +++ b/daemon.go @@ -377,7 +377,7 @@ func (daemon *Daemon) Processor(events <-chan ClientEvent) { target := strings.ToLower(cols[0]) for c := range daemon.clients { if c.nickname == target { - msg = fmt.Sprintf(":%s %s %s :%s", client, command, c.nickname, cols[1]) + msg = fmt.Sprintf(":%s %s %s %s", client, command, c.nickname, cols[1]) c.Msg(msg) break } diff --git a/room_test.go b/room_test.go index 11778fb..35c699a 100644 --- a/room_test.go +++ b/room_test.go @@ -83,7 +83,7 @@ func TestTwoUsers(t *testing.T) { <-conn1.outbound <-conn2.outbound } - conn1.inbound <- "PRIVMSG nick2 Hello" + conn1.inbound <- "PRIVMSG nick2 :Hello" conn1.inbound <- "PRIVMSG #foo :world" conn1.inbound <- "NOTICE #foo :world" if r := <-conn2.outbound; r != ":nick1!foo1@someclient PRIVMSG nick2 :Hello\r\n" {