From 46ef8967b16cad9b185f5fd1d6b18030290fc847 Mon Sep 17 00:00:00 2001 From: serr Date: Sun, 25 May 2025 19:12:06 +0300 Subject: [PATCH] =?UTF-8?q?=D1=83=D0=B1=D1=80=D0=B0=D0=BB=20=D0=BA=D0=BE?= =?UTF-8?q?=D0=BD=D0=B2=D0=B5=D1=80=D1=82=D0=B0=D1=86=D0=B8=D1=8E=20string?= =?UTF-8?q?=20=D0=B2=20[]byte=20=D0=B2=20=D0=BA=D0=BE=D0=BD=D1=82=D1=80?= =?UTF-8?q?=D0=BE=D0=BB=D0=BB=D0=B5=D1=80=D0=B5=20=D0=B3=D0=BB=D0=B0=D0=B2?= =?UTF-8?q?=D0=BD=D0=BE=D0=B9=20=D1=81=D1=82=D1=80=D0=B0=D0=BD=D0=B8=D1=86?= =?UTF-8?q?=D1=8B,=20=D1=81=D0=B4=D0=B5=D0=BB=D0=B0=D0=BB=20=D0=B7=D0=B0?= =?UTF-8?q?=D0=BF=D0=B8=D1=81=D1=8C=20=D0=B2=20w=20http.ResponseWriter=20?= =?UTF-8?q?=D1=87=D0=B5=D1=80=D0=B5=D0=B7=20fprintf?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mvc/controllers/controllers_pages/main.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mvc/controllers/controllers_pages/main.go b/mvc/controllers/controllers_pages/main.go index 4ae6b51..5cd3b9f 100644 --- a/mvc/controllers/controllers_pages/main.go +++ b/mvc/controllers/controllers_pages/main.go @@ -1,6 +1,7 @@ package controllers_pages import ( + "fmt" "log" "main/mvc/models" @@ -70,7 +71,7 @@ func sendCount(w http.ResponseWriter, data []byte) { func sendLove(w http.ResponseWriter) { w.Header().Set("Content-Type", "text/plain; charset=utf-8") w.WriteHeader(http.StatusOK) - w.Write([]byte("13.01.2005\n")) + fmt.Fprint(w, "13.01.2005\n") } // Ответ на метод LIMINAL @@ -78,6 +79,5 @@ func sendLiminal(w http.ResponseWriter) { w.Header().Set("Content-Type", "text/plain; charset=utf-8") w.WriteHeader(http.StatusOK) text := "If you're not careful and you slip out of reality in the wrong place, you'll end up in the Backstage, where there's nothing but the stench of old damp carpet, yellow-colored madness, the endless unbearable hum of fluorescent lights, and roughly six hundred million square miles of randomly arranged empty rooms.\n" - w.Write([]byte(text)) - + fmt.Fprint(w, text) }