We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 28dfa40 commit a9706b1Copy full SHA for a9706b1
config.go
@@ -87,7 +87,7 @@ func (cors *cors) applyCors(c *gin.Context) {
87
return
88
}
89
90
- if c.Request.Method == "OPTIONS" {
+ if c.Request.Method == http.MethodOptions {
91
cors.handlePreflight(c)
92
defer c.AbortWithStatus(cors.optionsResponseStatusCode)
93
} else {
0 commit comments