diff options
| author | Ho3ein <ho3ein.sanaei@gmail.com> | 2023-12-10 17:42:52 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-10 17:42:52 +0300 |
| commit | e3f1d3c892a1af48f27fdc36f273a55f38d13b40 (patch) | |
| tree | b11d0c1ed3c15c8f6f891a5e6df8e021d5db8ab6 /web/web.go | |
| parent | 36cf7c0a8fda915b51e75958ce729fd9a61a5c90 (diff) | |
| parent | 9fbe80f87f950673058f0001b3704251fa8b9243 (diff) | |
huge changes
Diffstat (limited to 'web/web.go')
| -rw-r--r-- | web/web.go | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -25,6 +25,7 @@ import ( sessions "github.com/Calidity/gin-sessions" "github.com/Calidity/gin-sessions/cookie" + "github.com/gin-contrib/gzip" "github.com/gin-gonic/gin" "github.com/robfig/cron/v3" ) @@ -174,6 +175,7 @@ func (s *Server) initRouter() (*gin.Engine, error) { if err != nil { return nil, err } + engine.Use(gzip.Gzip(gzip.DefaultCompression, gzip.WithExcludedPaths([]string{basePath + "panel/API/"}))) assetsBasePath := basePath + "assets/" store := cookie.NewStore(secret) |
