MCPcopy Create free account
hub / github.com/aiprodcoder/MIXAPI / CORS

Function CORS

middleware/cors.go:8–15  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6)
7
8func CORS() gin.HandlerFunc {
9 config := cors.DefaultConfig()
10 config.AllowAllOrigins = true
11 config.AllowCredentials = true
12 config.AllowMethods = []string{"GET", "POST", "PUT", "DELETE", "OPTIONS"}
13 config.AllowHeaders = []string{"*"}
14 return cors.New(config)
15}

Callers 3

SetDashboardRouterFunction · 0.92
SetApiRouterFunction · 0.92
SetRelayRouterFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected