打印请求方法
This commit is contained in:
parent
2a0681f3fe
commit
3072bed397
@ -67,7 +67,7 @@ func handle(fn handleFunc, prefix string, store *storage.Storage, server *settin
|
|||||||
})
|
})
|
||||||
|
|
||||||
clientIP := realip.FromRequest(r)
|
clientIP := realip.FromRequest(r)
|
||||||
log.Printf("%s: %v %s %v", r.URL.Path, status, clientIP, err)
|
log.Printf("%s %s: %v %s %v", r.Method, r.URL.Path, status, clientIP, err)
|
||||||
if status != 0 {
|
if status != 0 {
|
||||||
txt := http.StatusText(status)
|
txt := http.StatusText(status)
|
||||||
http.Error(w, strconv.Itoa(status)+" "+txt, status)
|
http.Error(w, strconv.Itoa(status)+" "+txt, status)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user