4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-06-26 21:19:22 +00:00

Fix megacheck / go vet issues

This commit is contained in:
Wim
2017-07-14 00:35:01 +02:00
parent 5af40db396
commit 6dee988b76
12 changed files with 46 additions and 59 deletions

View File

@ -4,6 +4,7 @@ import (
"strings"
)
/*
func tableformatter(nicks []string, nicksPerRow int, continued bool) string {
result := "|IRC users"
if continued {
@ -29,6 +30,7 @@ func tableformatter(nicks []string, nicksPerRow int, continued bool) string {
}
return result
}
*/
func plainformatter(nicks []string, nicksPerRow int) string {
return strings.Join(nicks, ", ") + " currently on IRC"

View File

@ -148,9 +148,9 @@ func (b *Birc) Send(msg config.Message) error {
func (b *Birc) doSend() {
rate := time.Millisecond * time.Duration(b.Config.MessageDelay)
throttle := time.Tick(rate)
throttle := time.NewTicker(rate)
for msg := range b.Local {
<-throttle
<-throttle.C
b.i.Privmsg(msg.Channel, msg.Username+msg.Text)
}
}