Signed-off-by: Alex Goodman <alex.goodman@anchore.com>
This commit is contained in:
Alex Goodman
2020-09-08 08:37:40 -04:00
parent c348d97fe0
commit 206fd8b7d3
19 changed files with 498 additions and 54 deletions
+7 -1
View File
@@ -1,6 +1,8 @@
package log
import "github.com/anchore/syft/syft/logger"
import (
"github.com/anchore/syft/syft/logger"
)
var Log logger.Logger = &nopLogger{}
@@ -8,6 +10,10 @@ func Errorf(format string, args ...interface{}) {
Log.Errorf(format, args...)
}
func Error(args ...interface{}) {
Log.Error(args...)
}
func Infof(format string, args ...interface{}) {
Log.Infof(format, args...)
}
+1
View File
@@ -3,6 +3,7 @@ package log
type nopLogger struct{}
func (l *nopLogger) Errorf(format string, args ...interface{}) {}
func (l *nopLogger) Error(args ...interface{}) {}
func (l *nopLogger) Infof(format string, args ...interface{}) {}
func (l *nopLogger) Info(args ...interface{}) {}
func (l *nopLogger) Debugf(format string, args ...interface{}) {}