diff --git a/internal/logger/logger.go b/internal/logger/logger.go index 68ecdbe..b9cdee0 100644 --- a/internal/logger/logger.go +++ b/internal/logger/logger.go @@ -25,5 +25,7 @@ func New() *log.Logger { logger.SetStyles(styles) + log.TimestampKey = "ts" + return logger } diff --git a/internal/writer/writer.go b/internal/writer/writer.go index 8581005..65419a4 100644 --- a/internal/writer/writer.go +++ b/internal/writer/writer.go @@ -34,8 +34,6 @@ func (w *logWriter) Write(p []byte) (n int, err error) { return 0, err } - w.Logger = w.With("ts", d["ts"]) - err = w.write(d) return