ソースを参照

fixed err: http: multiple response.WriteHeader calls

Mohamed Al Ashaal 7 年 前
コミット
7e5132e857
1 ファイル変更1 行追加0 行削除
  1. 1 0
      server.go

+ 1 - 0
server.go

@@ -45,6 +45,7 @@ func ServeHTTP() http.Handler {
 				loadbalancer.UpsertServer(testutils.ParseURI(upstream))
 			}
 			loadbalancer.ServeHTTP(res, req)
+			return
 		}
 		http.Error(res, "The request domain couldn't be found here", http.StatusNotImplemented)
 	})