잘못된 import 수정 2
This commit is contained in:
parent
ff77d2b7d1
commit
437417de21
|
@ -63,12 +63,7 @@ func NewOtherLogger(
|
|||
loglevel := zap.NewAtomicLevelAt(logLevel)
|
||||
logWriter := rotater.NewLogWriter(logFilename, maxSizeMb, maxBackup, maxDay, logDir)
|
||||
core := zapcore.NewCore(formatter, logWriter, loglevel)
|
||||
|
||||
if rotateSyncer, ok := logWriter.(logger.RotateSyncer); ok {
|
||||
closer = rotateSyncer.Close
|
||||
} else {
|
||||
closer = nopCloser
|
||||
}
|
||||
closer = logWriter.Close
|
||||
|
||||
options := []zap.Option{zap.ErrorOutput(defaultWriter)}
|
||||
logger = zap.New(core, options...).
|
||||
|
|
Loading…
Reference in New Issue