mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-10 18:56:55 +02:00
perf(logging): optimize multi-line message formatting
- Refactors the fmtMessage function to use strings.Builder - Simplifies multi-writer creation with a helper function - Updates the new console writer initialization pattern - Moves InitLogger function to the top - Fixed NewLoggerWithFixedLevel
This commit is contained in:
@@ -55,7 +55,7 @@ func NewState() config.State {
|
||||
entrypoint: entrypoint.NewEntrypoint(),
|
||||
task: task.RootTask("config", false),
|
||||
tmpLogBuf: tmpLogBuf,
|
||||
tmpLog: logging.NewLogger(tmpLogBuf),
|
||||
tmpLog: logging.NewLoggerWithFixedLevel(zerolog.InfoLevel, tmpLogBuf),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user