From 1a7c88a2b0df64a5d7476063c8d65c09a4e1ebf2 Mon Sep 17 00:00:00 2001 From: Mark Bates Date: Thu, 18 Jan 2018 10:24:31 -0500 Subject: [PATCH] fixed issue with multiple response headers being written for some prewares fixes #861 --- app.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/app.go b/app.go index 69f5fda1a..e6d31922f 100644 --- a/app.go +++ b/app.go @@ -188,10 +188,7 @@ func (a *App) processPreHandlers(res http.ResponseWriter, req *http.Request) boo sh := func(h http.Handler) bool { h.ServeHTTP(res, req) if br, ok := res.(*Response); ok { - if (br.Status < 200 || br.Status > 299) && br.Status > 0 { - return false - } - if br.Size > 0 { + if br.Status > 0 || br.Size > 0 { return false } }