From 57b8276afed59dc20dbb929115807a394e923640 Mon Sep 17 00:00:00 2001 From: Tanmoy Sarkar <57363826+tanmoysrt@users.noreply.github.com> Date: Wed, 6 Mar 2024 17:11:17 +0530 Subject: [PATCH] fix: socket closed error in firefox (#367) (cherry picked from commit 1106b0143d3fd20432d07e468698af8fd9a4474e) --- swiftwave_service/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/swiftwave_service/main.go b/swiftwave_service/main.go index 77d63d9228..64276c5c5f 100644 --- a/swiftwave_service/main.go +++ b/swiftwave_service/main.go @@ -106,7 +106,7 @@ func StartServer(config *system_config.Config, manager *core.ServiceManager, wor if strings.HasPrefix(c.Request().URL.Path, "/graphql") && strings.Compare(c.Request().Method, http.MethodGet) == 0 && strings.Compare(c.Request().URL.RawQuery, "") == 0 && - strings.Compare(c.Request().Header.Get("Connection"), "Upgrade") == 0 && + strings.Contains(c.Request().Header.Get("Connection"), "Upgrade") && strings.Compare(c.Request().Header.Get("Upgrade"), "websocket") == 0 { return true }