Explorar el Código

add remote addr in debug

Victor Vieux hace 12 años
padre
commit
a0f5fb7394
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      api.go

+ 1 - 1
api.go

@@ -878,7 +878,7 @@ func createRouter(srv *Server, logging bool) (*mux.Router, error) {
 			localMethod := method
 			localFct := fct
 			f := func(w http.ResponseWriter, r *http.Request) {
-				utils.Debugf("Calling %s %s", localMethod, localRoute)
+				utils.Debugf("Calling %s %s from %s", localMethod, localRoute, r.RemoteAddr)
 
 				if logging {
 					log.Println(r.Method, r.RequestURI)