diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-12 06:13:31 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-12 06:13:31 +0300 |
commit | 721529ce185614db20618132eae45dc4aa3d9921 (patch) | |
tree | ffeb84f02cf42898e9a7dbd36ff474e43fc98890 /app/models/project.rb | |
parent | ec14b0b4f853fdb94b0b3fe720a8d8440b2e77eb (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/project.rb')
-rw-r--r-- | app/models/project.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/models/project.rb b/app/models/project.rb index 5130a476332..46295545e91 100644 --- a/app/models/project.rb +++ b/app/models/project.rb @@ -3036,6 +3036,12 @@ class Project < ApplicationRecord deployments.where(id: deployment_id).fast_destroy_all end + def can_create_custom_domains? + return true if Gitlab::CurrentSettings.max_pages_custom_domains_per_project == 0 + + pages_domains.count < Gitlab::CurrentSettings.max_pages_custom_domains_per_project + end + private # overridden in EE |