separated logger middleware
This commit is contained in:
@@ -4,7 +4,11 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
type HandlerFunc = func(r *http.Request) (Response, error)
|
||||
type (
|
||||
HandlerFunc = func(r *http.Request) (Response, error)
|
||||
|
||||
Middleware = func(HandlerFunc) HandlerFunc
|
||||
)
|
||||
|
||||
func Handler(f HandlerFunc) http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
Reference in New Issue
Block a user