Add ETag header to avatars (#721)

This commit is contained in:
Bwko 2017-01-25 05:26:31 +01:00 committed by Lunny Xiao
parent 8093b3372e
commit 8555e888d8
7 changed files with 50 additions and 9 deletions

View file

@ -258,7 +258,9 @@ func (r *Router) NotFound(handlers ...Handler) {
validateHandlers(handlers)
r.notFound = func(rw http.ResponseWriter, req *http.Request) {
c := r.m.createContext(rw, req)
c.handlers = append(r.m.handlers, handlers...)
c.handlers = make([]Handler, 0, len(r.m.handlers)+len(handlers))
c.handlers = append(c.handlers, r.m.handlers...)
c.handlers = append(c.handlers, handlers...)
c.run()
}
}