Middleware upgrade (#554)

* Adds root level middleware

* Added todo

* Better way for extensions to be added.

* Bad conflict merge?
This commit is contained in:
Travis Reeder
2017-12-05 08:22:03 -08:00
committed by GitHub
parent 9a17c79a3b
commit 0798f9fac8
23 changed files with 660 additions and 287 deletions

View File

@@ -33,7 +33,7 @@ func main() {
type CustomMiddleware struct {
}
func (h *CustomMiddleware) Chain(next http.Handler) http.Handler {
func (h *CustomMiddleware) Handle(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
fmt.Println("CustomMiddleware called")