Skip to content

Commit

Permalink
default time encoder (#391)
Browse files Browse the repository at this point in the history
  • Loading branch information
zachcheu authored Jan 22, 2025
1 parent c1d9e26 commit cfcda81
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion utils/log/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
Expand Down Expand Up @@ -35,6 +35,9 @@ func (c Config) applyDefaults() Config {
if c.Encoding == "" {
c.Encoding = "console"
}
if c.EncodeTime == nil {
c.EncodeTime = zapcore.ISO8601TimeEncoder
}
return c
}

Expand Down

0 comments on commit cfcda81

Please sign in to comment.