aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--irc.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/irc.go b/irc.go
index afc9f96..8fe22d1 100644
--- a/irc.go
+++ b/irc.go
@@ -65,6 +65,13 @@ func ircBotSession() error {
return
}
case "JOIN":
+ c, ok := msg.Source.(irc.Client)
+ if !ok {
+ clog.Error("IRC server told us a non-client is joining a channel...")
+ }
+ if c.Nick != config.IRC.Nick {
+ continue
+ }
_, err = conn.WriteString("PRIVMSG #chat :test\r\n")
if err != nil {
readLoopError <- err