From 399789811ecab11f7dfb775f83d063b20167bb1d Mon Sep 17 00:00:00 2001 From: Wim Date: Thu, 8 Nov 2018 00:46:34 +0100 Subject: Make gocritic linter happy --- bridge/irc/irc.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'bridge/irc') diff --git a/bridge/irc/irc.go b/bridge/irc/irc.go index 25f6beec..0702575b 100644 --- a/bridge/irc/irc.go +++ b/bridge/irc/irc.go @@ -63,8 +63,7 @@ func New(cfg *bridge.Config) bridge.Bridger { } func (b *Birc) Command(msg *config.Message) string { - switch msg.Text { - case "!users": + if msg.Text == "!users" { b.i.Handlers.Add(girc.RPL_NAMREPLY, b.storeNames) b.i.Handlers.Add(girc.RPL_ENDOFNAMES, b.endNames) b.i.Cmd.SendRaw("NAMES " + msg.Channel) @@ -237,7 +236,7 @@ func (b *Birc) Send(msg config.Message) (string, error) { } if len(b.Local) < b.MessageQueue { if len(b.Local) == b.MessageQueue-1 { - text = text + " " + text += " " } b.Local <- config.Message{Text: text, Username: msg.Username, Channel: msg.Channel, Event: msg.Event} } else { -- cgit v1.2.3