From 4749352bbd3ed69162f856ad054c30f04a249b89 Mon Sep 17 00:00:00 2001 From: kolaente Date: Fri, 7 Sep 2018 08:43:23 +0200 Subject: [PATCH] Fixed cors (Again...) --- routes/routes.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/routes/routes.go b/routes/routes.go index 6b6aabf5ccc..3bedc8b4353 100644 --- a/routes/routes.go +++ b/routes/routes.go @@ -78,8 +78,20 @@ func RegisterRoutes(e *echo.Echo) { a.OPTIONS("/users/:id", SetCORSHeader) a.OPTIONS("/lists", SetCORSHeader) a.OPTIONS("/lists/:id", SetCORSHeader) + a.OPTIONS("/lists/:id/teams", SetCORSHeader) + a.OPTIONS("/lists/:id/teams/:id", SetCORSHeader) + a.OPTIONS("/lists/:id/users", SetCORSHeader) + a.OPTIONS("/lists/:id/users/:id", SetCORSHeader) a.OPTIONS("/namespaces", SetCORSHeader) a.OPTIONS("/namespaces/:id", SetCORSHeader) + a.OPTIONS("/namespaces/:id/lists", SetCORSHeader) + a.OPTIONS("/namespaces/:id/users", SetCORSHeader) + a.OPTIONS("/namespaces/:id/users/:id", SetCORSHeader) + a.OPTIONS("/tasks/:id", SetCORSHeader) + a.OPTIONS("/tasks", SetCORSHeader) + a.OPTIONS("/teams", SetCORSHeader) + a.OPTIONS("/teams/:id", SetCORSHeader) + a.OPTIONS("/teams/:id/members", SetCORSHeader) a.POST("/login", apiv1.Login) a.POST("/register", apiv1.RegisterUser)