added more logic

This commit is contained in:
2024-05-14 15:12:18 +03:00
parent c68de6705a
commit 16b6850635
4 changed files with 152 additions and 25 deletions

View File

@@ -33,5 +33,5 @@ func (con Connection) GetUsers(c *gin.Context) {
func LoadGroup(group *gin.RouterGroup, client *mongo.Client) {
connection := Connection{connection: client}
group.Use(auth.AuthorizedTo(0)).GET("/", connection.GetUsers)
group.GET("/", auth.AuthorizedTo(0), connection.GetUsers)
}