We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1780e59 commit e06fc39Copy full SHA for e06fc39
mqmetric/log.go
@@ -26,6 +26,7 @@ import (
26
type Logger struct {
27
Debug func(string, ...interface{})
28
Info func(string, ...interface{})
29
+ Warn func(string, ...interface{})
30
Error func(string, ...interface{})
31
}
32
@@ -45,6 +46,11 @@ func logInfo(format string, v ...interface{}) {
45
46
logger.Info(format, v...)
47
48
49
+func logWarn(format string, v ...interface{}) {
50
+ if logger != nil && logger.Warn != nil {
51
+ logger.Warn(format, v...)
52
+ }
53
+}
54
55
// Errors should be reported always. Also use this for what you might
56
// think of as warnings.
0 commit comments