mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-23 01:33:44 +02:00
Restricting access to fork functioanlity to users with Code access (#2542)
Signed-off-by: Jonas Franz <info@jonasfranz.software>
This commit is contained in:
1 parent
fc0c6f48c7
commit
91788e0200
3 files changed
+74
-3
No files matched your search
+1
-1
@@ -648,7 +648,7 @@ func (repo *Repository) UpdateSize() error {
|
||||
|
||||
// CanBeForked returns true if repository meets the requirements of being forked.
|
||||
func (repo *Repository) CanBeForked() bool {
|
||||
return !repo.IsBare
|
||||
return !repo.IsBare && repo.UnitEnabled(UnitTypeCode)
|
||||
}
|
||||
|
||||
// CanEnablePulls returns true if repository meets the requirements of accepting pulls.
|
||||
|
||||
Reference in new issue
Block a user