From 5296edc4a7696c20998b810c6f9d91ff7ff770c0 Mon Sep 17 00:00:00 2001 From: Senad Uka Date: Thu, 9 Nov 2023 10:06:06 +0100 Subject: [PATCH] Upstream sync --- middlewares/cors.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/middlewares/cors.go b/middlewares/cors.go index 603a871..af8980b 100644 --- a/middlewares/cors.go +++ b/middlewares/cors.go @@ -11,7 +11,7 @@ func CORSMiddleware() gin.HandlerFunc { c.Writer.Header().Set("Access-Control-Allow-Origin", "*") c.Writer.Header().Set("Access-Control-Allow-Credentials", "true") c.Writer.Header().Set("Access-Control-Allow-Headers", "Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization, accept, origin, Cache-Control, X-Requested-With") - c.Writer.Header().Set("Access-Control-Allow-Methods", "POST, OPTIONS, GET, PUT") + c.Writer.Header().Set("Access-Control-Allow-Methods", "POST, OPTIONS, GET, PUT, PATCH") if c.Request.Method == "OPTIONS" { c.AbortWithStatus(204)