1
Fork 0
mirror of https://github.com/caddyserver/caddy.git synced 2024-12-16 21:56:40 -05:00

logging: Colorize output in all cases of stdout/stderr

This commit is contained in:
Matthew Holt 2020-04-09 13:06:06 -06:00
parent d89ad2fd5b
commit 6e4132eb89
No known key found for this signature in database
GPG key ID: 2A349DD577D586A5

View file

@ -423,7 +423,8 @@ func (cl *CustomLog) provision(ctx Context, logging *Logging) error {
// only allow colorized output if this log is going to stdout or stderr
var colorize bool
switch cl.writerOpener.(type) {
case *StdoutWriter, *StderrWriter:
case StdoutWriter, StderrWriter,
*StdoutWriter, *StderrWriter:
colorize = true
}
cl.encoder = newDefaultProductionLogEncoder(colorize)