Add configuration option for default permission to create Organizations (#1686)

This commit is contained in:
Lauris BH
2017-05-08 22:51:53 +03:00
committed by Kim "BKC" Carlbäcker
parent a85c5ab9ff
commit 51d0becb42
13 changed files with 27 additions and 5 deletions

View File

@ -706,7 +706,7 @@ func CreateUser(u *User) (err error) {
return err
}
u.EncodePasswd()
u.AllowCreateOrganization = true
u.AllowCreateOrganization = setting.Service.DefaultAllowCreateOrganization
u.MaxRepoCreation = -1
sess := x.NewSession()