mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
EnableUnit() -> UnitEnabled() (#2242)
This commit is contained in:
@@ -31,8 +31,8 @@ const (
|
||||
|
||||
// MustEnableWiki check if wiki is enabled, if external then redirect
|
||||
func MustEnableWiki(ctx *context.Context) {
|
||||
if !ctx.Repo.Repository.EnableUnit(models.UnitTypeWiki) &&
|
||||
!ctx.Repo.Repository.EnableUnit(models.UnitTypeExternalWiki) {
|
||||
if !ctx.Repo.Repository.UnitEnabled(models.UnitTypeWiki) &&
|
||||
!ctx.Repo.Repository.UnitEnabled(models.UnitTypeExternalWiki) {
|
||||
ctx.Handle(404, "MustEnableWiki", nil)
|
||||
return
|
||||
}
|
||||
|
Reference in New Issue
Block a user