Fixed cors (Again...)

This commit is contained in:
kolaente 2018-09-07 08:43:23 +02:00
parent 21774fd447
commit 4749352bbd
No known key found for this signature in database
GPG key ID: F40E70337AB24C9B

View file

@ -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)