Преглед изворни кода

add modules supports

tags/v0.9.0
jimzhan пре 10 година
родитељ
комит
14c1b13f4f
1 измењених фајлова са 2 додато и 2 уклоњено
  1. +2
    -2
      server.go

+ 2
- 2
server.go Прегледај датотеку

} }


// Use add the middleware module into the stack chain. // Use add the middleware module into the stack chain.
func (self *server) Use(module ...func(http.Handler) http.Handler) {
self.middleware.stack = append(self.middleware.stack, module...)
func (self *server) Use(modules ...func(http.Handler) http.Handler) {
self.middleware.stack = append(self.middleware.stack, modules...)
} }


// Get is a shortcut for mux.HandleFunc(pattern, handler).Methods("GET"), // Get is a shortcut for mux.HandleFunc(pattern, handler).Methods("GET"),

Loading…
Откажи
Сачувај