Skip to content

Commit

Permalink
log enhance
Browse files Browse the repository at this point in the history
  • Loading branch information
AbericYang committed Jun 4, 2020
1 parent 099e0aa commit 7353ff0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions log/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,11 @@ func Field(key string, value interface{}) FieldInter {
return &field{key: key, value: value}
}

// Server 当前服务
func Server(value string) FieldInter {
return &field{key: "service", value: value}
}

// Err 自定义输出错误
func Err(err error) FieldInter {
if nil != err {
Expand Down

0 comments on commit 7353ff0

Please sign in to comment.