add panic error for raw

This commit is contained in:
zhiqiang feng
2020-12-28 17:27:24 +08:00
parent 35c1966e87
commit 98425409a7
+3
View File
@@ -132,6 +132,9 @@ func initLog() {
rawFile,
rotatelogs.WithMaxAge(60*24*time.Hour),
rotatelogs.WithRotationTime(time.Hour))
if err != nil {
panic(err)
}
filePriority := zap.LevelEnablerFunc(func(lvl zapcore.Level) bool {
return lvl >= zapcore.DebugLevel