1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-20 03:17:04 +00:00

Update to 6.0.1 - use the response recorder whenever you need it. Read HISTORY.md

This commit is contained in:
Gerasimos (Makis) Maropoulos
2017-01-04 15:16:53 +02:00
parent 8bbd9f8fc5
commit 058d70e533
12 changed files with 531 additions and 210 deletions

View File

@@ -131,12 +131,12 @@ func (w *webfs) Build() HandlerFunc {
}
w.handler = func(ctx *Context) {
writer := ctx.ResponseWriter.ResponseWriter
writer := ctx.ResponseWriter
if w.gzip && ctx.clientAllowsGzip() {
ctx.ResponseWriter.Header().Add(varyHeader, acceptEncodingHeader)
ctx.SetHeader(contentEncodingHeader, "gzip")
gzipResWriter := acquireGzipResponseWriter(ctx.ResponseWriter.ResponseWriter)
gzipResWriter := acquireGzipResponseWriter(ctx.ResponseWriter) //.ResponseWriter)
writer = gzipResWriter
defer releaseGzipResponseWriter(gzipResWriter)
}