Skip to content

Commit

Permalink
Return a simple logger for non-request context.
Browse files Browse the repository at this point in the history
  • Loading branch information
KaKa Lee committed Mar 13, 2017
1 parent 8bdcbfc commit 67fbd36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lg.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func L(ctx context.Context) *zap.Logger {
if l, ok := ctx.Value(requestIDKey).(*zap.Logger); ok {
return l
}
panic("Should have request logger.")
return log
}

// LogRequest to log every request.
Expand Down

0 comments on commit 67fbd36

Please sign in to comment.