fix: comment NullLogger
This commit is contained in:
parent
a2b35caa31
commit
e6d805119f
@ -6,8 +6,12 @@ import (
|
|||||||
log "github.com/sirupsen/logrus"
|
log "github.com/sirupsen/logrus"
|
||||||
)
|
)
|
||||||
|
|
||||||
type NullLogger struct {}
|
// NullLogger is used to create a new JobLogger to discard logs. This
|
||||||
|
// will prevent these logs from being logged to the stdout, but
|
||||||
|
// forward them to the Reporter via its hook.
|
||||||
|
type NullLogger struct{}
|
||||||
|
|
||||||
|
// WithJobLogger creates a new logrus.Logger that will discard all logs.
|
||||||
func (n NullLogger) WithJobLogger() *log.Logger {
|
func (n NullLogger) WithJobLogger() *log.Logger {
|
||||||
logger := log.New()
|
logger := log.New()
|
||||||
logger.SetOutput(io.Discard)
|
logger.SetOutput(io.Discard)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user