bugfix reports
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2026-01-14 13:51:30 +11:00
parent 013ae4568e
commit b9ab34db0a
13 changed files with 404 additions and 115 deletions

View File

@@ -25,15 +25,14 @@ func (l *LoggingMiddleware) ServeHTTP(w http.ResponseWriter, r *http.Request) {
start := time.Now()
l.handler.ServeHTTP(w, r)
query := r.URL.RawQuery
if query == "" {
query = "-"
requestPath := r.URL.RequestURI()
if requestPath == "" {
requestPath = r.URL.Path
}
l.logger.Debug(
"Request recieved",
slog.String("method", r.Method),
slog.String("path", r.URL.Path),
slog.String("query", query),
slog.String("request", requestPath),
slog.String("remote", r.RemoteAddr),
slog.Duration("duration", time.Since(start)),
)