1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Mock access logs don't show up in non-debug mode

This commit is contained in:
shin- 2013-08-05 16:22:46 +02:00
parent 484ba4a8c5
commit 9159c819c3

View file

@ -3,10 +3,10 @@ package registry
import (
"encoding/json"
"fmt"
"github.com/dotcloud/docker/utils"
"github.com/gorilla/mux"
"io"
"io/ioutil"
"log"
"net/http"
"net/http/httptest"
"net/url"
@ -96,7 +96,7 @@ func init() {
func handlerAccessLog(handler http.Handler) http.Handler {
logHandler := func(w http.ResponseWriter, r *http.Request) {
log.Printf("%s \"%s %s\"", r.RemoteAddr, r.Method, r.URL)
utils.Debugf("%s \"%s %s\"", r.RemoteAddr, r.Method, r.URL)
handler.ServeHTTP(w, r)
}
return http.HandlerFunc(logHandler)