From 0d9536ee3fae8a7429acc3cfb21598a981925ae2 Mon Sep 17 00:00:00 2001 From: Knut Ahlers Date: Thu, 10 Feb 2022 00:30:40 +0100 Subject: [PATCH] [editor] Fix: Upgrade contains a header send, error must not send headers Signed-off-by: Knut Ahlers --- configEditor_global.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configEditor_global.go b/configEditor_global.go index 10936e7..6a0e682 100644 --- a/configEditor_global.go +++ b/configEditor_global.go @@ -135,7 +135,7 @@ func configEditorGlobalGetUser(w http.ResponseWriter, r *http.Request) { func configEditorGlobalSubscribe(w http.ResponseWriter, r *http.Request) { conn, err := upgrader.Upgrade(w, r, nil) if err != nil { - http.Error(w, err.Error(), http.StatusInternalServerError) + log.WithError(err).Error("Unable to initialize websocket") return } defer conn.Close()