change cookie name

This commit is contained in:
Alireza Ahmadi
2024-02-27 00:59:12 +01:00
parent 6b174762e2
commit 225b3fc3a5

View File

@@ -179,7 +179,7 @@ func (s *Server) initRouter() (*gin.Engine, error) {
assetsBasePath := basePath + "assets/"
store := cookie.NewStore(secret)
engine.Use(sessions.Sessions("session", store))
engine.Use(sessions.Sessions("x-ui", store))
engine.Use(func(c *gin.Context) {
c.Set("base_path", basePath)
})