all repos — website @ 5a350395ba1163b03242a185b397cd1dbd50417b

My website

Revert "Disable stdout request logging in production"

This reverts commit fcc59c8caff01282e45191122c9fb5bb24e89fd7.
Alan Pearce alan@alanpearce.eu
Thu, 28 Nov 2024 14:55:35 +0100
commit

5a350395ba1163b03242a185b397cd1dbd50417b

parent

0240a3f3d9bd8688ee630ebc6110c78f3a84e953

1 files changed, 5 insertions(+), 9 deletions(-)

jump to
M internal/server/server.gointernal/server/server.go
@@ -204,15 +204,11 @@ } else { 		loggingMux.Handle("/", mux)
 	}
 
-	if runtimeConfig.Development {
-		top.Handle("/",
-			serverHeaderHandler(
-				wrapHandlerWithLogging(loggingMux, log),
-			),
-		)
-	} else {
-		top.Handle("/", serverHeaderHandler(loggingMux))
-	}
+	top.Handle("/",
+		serverHeaderHandler(
+			wrapHandlerWithLogging(loggingMux, log),
+		),
+	)
 
 	top.HandleFunc("/health", func(w http.ResponseWriter, _ *http.Request) {
 		w.WriteHeader(http.StatusNoContent)