aboutsummaryrefslogtreecommitdiffstats
path: root/logger/loggers.go
diff options
context:
space:
mode:
Diffstat (limited to 'logger/loggers.go')
-rw-r--r--logger/loggers.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/logger/loggers.go b/logger/loggers.go
index 25263853a..42c8cbc07 100644
--- a/logger/loggers.go
+++ b/logger/loggers.go
@@ -28,7 +28,6 @@ const (
InfoLevel
DebugLevel
DebugDetailLevel
- JsonLevel = 1000
)
// A Logger prints messages prefixed by a given tag. It provides named
@@ -43,11 +42,11 @@ func NewLogger(tag string) *Logger {
}
func (logger *Logger) Sendln(level LogLevel, v ...interface{}) {
- logMessageC <- message{level, logger.tag + fmt.Sprintln(v...)}
+ logMessageC <- stdMsg{level, logger.tag + fmt.Sprintln(v...)}
}
func (logger *Logger) Sendf(level LogLevel, format string, v ...interface{}) {
- logMessageC <- message{level, logger.tag + fmt.Sprintf(format, v...)}
+ logMessageC <- stdMsg{level, logger.tag + fmt.Sprintf(format, v...)}
}
// Errorln writes a message with ErrorLevel.
@@ -129,6 +128,6 @@ func (logger *JsonLogger) LogJson(v JsonLog) {
}
jsontxt, _ := json.Marshal(obj)
- logMessageC <- message{JsonLevel, string(jsontxt)}
+ logMessageC <- (jsonMsg(jsontxt))
}