Ver código fonte

Handle mode characters in NAMES correctly

tags/v0.1.4
Russ Garrett 7 anos atrás
pai
commit
4dfc49e50d
Nenhuma conta vinculada ao e-mail do autor do commit
1 arquivos alterados com 2 adições e 0 exclusões
  1. 2
    0
      auth.go

+ 2
- 0
auth.go Ver arquivo

@@ -26,6 +26,8 @@ func (i *IRCCat) handleNames(e *irc.Event) {
26 26
 	if e.Arguments[2] == i.auth_channel {
27 27
 		nicks := strings.Split(e.Arguments[3], " ")
28 28
 		for _, nick := range nicks {
29
+			// TODO: this is probably not an optimal way of trimming the mode characters.
30
+			nick = strings.TrimLeft(nick, "@%+")
29 31
 			i.auth_users[nick] = true
30 32
 		}
31 33
 	}

Carregando…
Cancelar
Salvar