From 1f5005e636edf8b3d59d0f87e74a7dbd9d09f8ea Mon Sep 17 00:00:00 2001
From: Rohith Jayawardene <gambol99@gmail.com>
Date: Mon, 8 Jan 2018 09:49:33 +0000
Subject: [PATCH] Websocket Fix (#303)

The http2FancyWriter does not implement the http.Hijacker method causing the websocket upgrade to throw an exception. This PR fixes the issues by forcing the selection of httpFancyWriter{}
---
 middleware.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/middleware.go b/middleware.go
index 8bb3005..e39c1b6 100644
--- a/middleware.go
+++ b/middleware.go
@@ -51,7 +51,7 @@ func entrypointMiddleware(next http.Handler) http.Handler {
 
 		// continue the flow
 		scope := &RequestScope{}
-		resp := middleware.NewWrapResponseWriter(w, 2)
+		resp := middleware.NewWrapResponseWriter(w, 1)
 		next.ServeHTTP(resp, req.WithContext(context.WithValue(req.Context(), contextScopeName, scope)))
 
 		// place back the original uri for proxying request
-- 
GitLab