From 305372efe397e3b0af4ae5a30f8bd2f30c68ffcf Mon Sep 17 00:00:00 2001 From: Norwin Date: Tue, 26 Jul 2022 16:34:14 +0200 Subject: fix enabling repo packages when projects are off (#20486) --- routers/web/repo/setting.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'routers') diff --git a/routers/web/repo/setting.go b/routers/web/repo/setting.go index 5ded0561c6..7f6b0feafb 100644 --- a/routers/web/repo/setting.go +++ b/routers/web/repo/setting.go @@ -476,7 +476,7 @@ func SettingsPost(ctx *context.Context) { deleteUnitTypes = append(deleteUnitTypes, unit_model.TypeProjects) } - if form.EnablePackages && !unit_model.TypeProjects.UnitGlobalDisabled() { + if form.EnablePackages && !unit_model.TypePackages.UnitGlobalDisabled() { units = append(units, repo_model.RepoUnit{ RepoID: repo.ID, Type: unit_model.TypePackages, -- cgit v1.2.3