Browse Source

style: Log time

lejianwen 11 months ago
parent
commit
5660d40514
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/logger/logger.go

+ 1 - 1
lib/logger/logger.go

@@ -21,7 +21,7 @@ type Config struct {
21
 func New(c *Config) *log.Logger {
21
 func New(c *Config) *log.Logger {
22
 	log.SetFormatter(&nested.Formatter{
22
 	log.SetFormatter(&nested.Formatter{
23
 		// HideKeys:        true,
23
 		// HideKeys:        true,
24
-		TimestampFormat: "2006-01-02 15:04:05",
24
+		TimestampFormat: "[2006-01-02 15:04:05]",
25
 		NoColors:        true,
25
 		NoColors:        true,
26
 		NoFieldsColors:  true,
26
 		NoFieldsColors:  true,
27
 		//FieldsOrder:     []string{"name", "age"},
27
 		//FieldsOrder:     []string{"name", "age"},