mirror of https://github.com/cloudreve/Cloudreve
fix(router): remove unused get all group route
parent
a517f41ab1
commit
95d2b5804e
2
assets
2
assets
|
@ -1 +1 @@
|
|||
Subproject commit cdbc2861f9b8d13ec311fd4ee394a3987a604640
|
||||
Subproject commit 1c87bc1c1652db9d31e83f74466dd6e5dc9fb16f
|
|
@ -373,24 +373,6 @@ func UserSearch(c *gin.Context) {
|
|||
})
|
||||
}
|
||||
|
||||
// GetGroupList list all groups for options
|
||||
func GetGroupList(c *gin.Context) {
|
||||
u, err := user.ListAllGroups(c)
|
||||
if err != nil {
|
||||
c.JSON(200, serializer.Err(c, err))
|
||||
c.Abort()
|
||||
return
|
||||
}
|
||||
|
||||
hasher := dependency.FromContext(c).HashIDEncoder()
|
||||
c.JSON(200, serializer.Response{
|
||||
Data: lo.Map(u, func(item *ent.Group, index int) *user.Group {
|
||||
g := user.BuildGroup(item, hasher)
|
||||
return user.RedactedGroup(g)
|
||||
}),
|
||||
})
|
||||
}
|
||||
|
||||
// ListPublicShare lists all public shares for given user
|
||||
func ListPublicShare(c *gin.Context) {
|
||||
service := ParametersFromContext[*share.ListShareService](c, share.ListShareParamCtx{})
|
||||
|
|
|
@ -1101,12 +1101,6 @@ func initMasterRouter(dep dependency.Dep) *gin.Engine {
|
|||
}
|
||||
}
|
||||
|
||||
group := auth.Group("group")
|
||||
{
|
||||
// list all groups for options
|
||||
group.GET("list", controllers.GetGroupList)
|
||||
}
|
||||
|
||||
// WebDAV and devices
|
||||
devices := auth.Group("devices")
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue