tyding up and tryinng to get tokens in docs to work

This commit is contained in:
Samuel Högbom Aronson 2024-03-19 00:27:31 +01:00
parent ad85194d4f
commit 8711f9a20d
3 changed files with 28 additions and 11 deletions

View file

@ -11,7 +11,7 @@ import (
// Register is a simple handler that registers a new user
//
// @Summary Register a new user
// @Summary Register
// @Description Register a new user
// @Tags User
// @Accept json
@ -40,7 +40,7 @@ func (gs *GState) Register(c *fiber.Ctx) error {
// This path should obviously be protected in the future
// UserDelete deletes a user from the database
//
// @Summary Deletes a user
// @Summary UserDelete
// @Description UserDelete deletes a user from the database
// @Tags User
// @Accept json
@ -120,8 +120,9 @@ func (gs *GState) Login(c *fiber.Ctx) error {
// LoginRenew is a simple handler that renews the token
//
// @Summary renews the users token
// @Summary LoginRenews
// @Description renews the users token
// @Security bererToken
// @Tags User
// @Accept json
// @Produce plain
@ -149,7 +150,7 @@ func (gs *GState) LoginRenew(c *fiber.Ctx) error {
// ListAllUsers is a handler that returns a list of all users in the application database
//
// @Summary Lists users
// @Summary ListsAllUsers
// @Description lists all users
// @Tags User
// @Accept json
@ -169,7 +170,7 @@ func (gs *GState) ListAllUsers(c *fiber.Ctx) error {
return c.JSON(users)
}
// @Summary promote user to admin
// @Summary PromoteToAdmin
// @Description promote chosen user to admin
// @Tags User
// @Accept json