From 746b4f15e7ab24d528909ae150b3d311ca4bbbf0 Mon Sep 17 00:00:00 2001 From: qowevisa Date: Wed, 14 Aug 2024 15:05:55 +0300 Subject: [PATCH] Add Content-Type to AllowHeaders --- cmd/http-server/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/http-server/main.go b/cmd/http-server/main.go index fe8395f..2198f94 100644 --- a/cmd/http-server/main.go +++ b/cmd/http-server/main.go @@ -34,7 +34,7 @@ func main() { r.Use(cors.New(cors.Config{ AllowOrigins: []string{"*"}, AllowMethods: []string{"GET", "DELETE", "PUT", "PATCH", "OPTIONS"}, - AllowHeaders: []string{"Origin"}, + AllowHeaders: []string{"Origin", "Content-Type"}, ExposeHeaders: []string{"Content-Length"}, AllowCredentials: true, MaxAge: 12 * time.Hour,