diff --git a/models/repo.go b/models/repo.go index 52325f2623291..c795deee8db72 100644 --- a/models/repo.go +++ b/models/repo.go @@ -1347,6 +1347,12 @@ func createRepository(e *xorm.Session, doer, u *User, repo *Repository) (err err Type: tp, Config: &IssuesConfig{EnableTimetracker: setting.Service.DefaultEnableTimetracking, AllowOnlyContributorsToTrackTime: setting.Service.DefaultAllowOnlyContributorsToTrackTime}, }) + } else if tp == UnitTypePullRequests { + units = append(units, RepoUnit{ + RepoID: repo.ID, + Type: tp, + Config: &PullRequestsConfig{AllowMerge: true, AllowRebase: true, AllowSquash: true}, + }) } else { units = append(units, RepoUnit{ RepoID: repo.ID,