mirror of
https://github.com/datarhei/core.git
synced 2025-12-24 13:07:56 +08:00
Remove zstd from default compressions
This commit is contained in:
@@ -81,7 +81,7 @@ var DefaultConfig = Config{
|
||||
Skipper: middleware.DefaultSkipper,
|
||||
Level: DefaultCompression,
|
||||
MinLength: 0,
|
||||
Schemes: []Scheme{GzipScheme, ZstdScheme},
|
||||
Schemes: []Scheme{GzipScheme},
|
||||
}
|
||||
|
||||
// ContentTypesSkipper returns a Skipper based on the list of content types
|
||||
|
||||
@@ -488,9 +488,10 @@ func (s *server) HTTPStatus() map[int]uint64 {
|
||||
|
||||
func (s *server) setRoutes() {
|
||||
gzipMiddleware := mwcompress.NewWithConfig(mwcompress.Config{
|
||||
Skipper: mwcompress.ContentTypeSkipper(nil),
|
||||
Level: mwcompress.BestSpeed,
|
||||
MinLength: 1000,
|
||||
Skipper: mwcompress.ContentTypeSkipper(nil),
|
||||
Schemes: []mwcompress.Scheme{mwcompress.GzipScheme},
|
||||
})
|
||||
|
||||
// API router grouo
|
||||
@@ -532,6 +533,7 @@ func (s *server) setRoutes() {
|
||||
Skipper: mwcompress.ContentTypeSkipper(s.gzip.mimetypes),
|
||||
Level: mwcompress.BestSpeed,
|
||||
MinLength: 1000,
|
||||
Schemes: []mwcompress.Scheme{mwcompress.GzipScheme},
|
||||
}))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user