web: small fixes - mainly in docs
continuous-integration/drone the build is pending Details

This commit is contained in:
Geno 2021-07-19 18:35:44 +02:00
parent b10fc5b588
commit fb766ca32b
3 changed files with 3 additions and 4 deletions

View File

@ -26,6 +26,7 @@ type Status struct {
Extras interface{} `json:"extras,omitempty"` Extras interface{} `json:"extras,omitempty"`
} }
// Register status module
// @Summary Show Status of current API // @Summary Show Status of current API
// @Description Show version and status // @Description Show version and status
// @Tags status // @Tags status

View File

@ -14,10 +14,8 @@ var (
func TestRun(t *testing.T) { func TestRun(t *testing.T) {
assert := assert.New(t) assert := assert.New(t)
ModuleRegister(func(_ *gin.Engine, _ *Service) {
})
s := &Service{AccessLog: true, Listen: "8.8.8.8:80"} s := &Service{AccessLog: true, Listen: "8.8.8.8:80"}
s.ModuleRegister(func(_ *gin.Engine, _ *Service) {})
// HTTP - failed // HTTP - failed
err := s.Run() err := s.Run()
assert.Error(err) assert.Error(err)

View File

@ -6,7 +6,7 @@ import (
"github.com/gin-gonic/gin" "github.com/gin-gonic/gin"
) )
// LoadSessions starts session handling for s. // LoadSession starts session handling for s.
func (s *Service) LoadSession(r *gin.Engine) { func (s *Service) LoadSession(r *gin.Engine) {
store := cookie.NewStore([]byte(s.Session.Secret)) store := cookie.NewStore([]byte(s.Session.Secret))
r.Use(sessions.Sessions(s.Session.Name, store)) r.Use(sessions.Sessions(s.Session.Name, store))