ssh-chat/logger.go

21 lines
325 B
Go
Raw Normal View History

package sshchat
2014-12-07 08:31:23 +01:00
import (
"io/ioutil"
"github.com/alexcesaro/log"
2014-12-07 08:31:23 +01:00
"github.com/alexcesaro/log/golog"
)
var logger *golog.Logger
2019-01-25 18:07:34 +01:00
// SetLogger sets the package logging to use l.
func SetLogger(l *golog.Logger) {
logger = l
}
func init() {
// Set a default null logger
SetLogger(golog.New(ioutil.Discard, log.Debug))
}