Solve the integration swagger into the gin framework, access the Chinese garbled problem in the json returned by swagger/doc.json.
This commit is contained in:
parent
d488a69274
commit
9c85c19254
|
|
@ -69,7 +69,7 @@ func CustomWrapHandler(config *Config, h *webdav.Handler) gin.HandlerFunc {
|
|||
} else if strings.HasSuffix(path, ".js") {
|
||||
c.Header("Content-Type", "application/javascript")
|
||||
} else if strings.HasSuffix(path, ".json") {
|
||||
c.Header("Content-Type", "application/json")
|
||||
c.Header("Content-Type", "application/json; charset=utf-8")
|
||||
}
|
||||
|
||||
switch path {
|
||||
|
|
|
|||
Loading…
Reference in New Issue