From e8d2c50cd9348cddc830c90c7d49c96df3005c63 Mon Sep 17 00:00:00 2001 From: a Date: Mon, 24 Jun 2024 11:51:45 -0500 Subject: [PATCH] resolve logging --- logging.go | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/logging.go b/logging.go index 09bf8f84..b63c1eb0 100644 --- a/logging.go +++ b/logging.go @@ -16,7 +16,6 @@ package caddy import ( "encoding/json" - "flag" "fmt" "io" "log" @@ -700,12 +699,7 @@ type defaultCustomLog struct { // and enables INFO-level logs and higher. func newDefaultProductionLog() (*defaultCustomLog, error) { cl := new(CustomLog) - f := flag.Lookup("test.v") - if (f != nil && f.Value.String() != "true") || strings.Contains(os.Args[0], ".test") { - cl.writerOpener = &DiscardWriter{} - } else { - cl.writerOpener = StderrWriter{} - } + cl.writerOpener = StderrWriter{} var err error cl.writer, err = cl.writerOpener.OpenWriter()