mirror of
https://github.com/go-gitea/gitea
synced 2025-08-17 15:08:27 +00:00
Backport #21540 At the moment, If admin disable Packages, still show the Packages on the admin dashboard. This patch added a check to hide the Packages entry.
This commit is contained in:
@@ -566,6 +566,8 @@ func RegisterRoutes(m *web.Route) {
|
||||
m.Post("/delete", admin.DeleteNotices)
|
||||
m.Post("/empty", admin.EmptyNotices)
|
||||
})
|
||||
}, func(ctx *context.Context) {
|
||||
ctx.Data["EnablePackages"] = setting.Packages.Enabled
|
||||
}, adminReq)
|
||||
// ***** END: Admin *****
|
||||
|
||||
|
Reference in New Issue
Block a user