debian-mirror-gitlab/app/helpers/projects/pages_helper.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
329 B
Ruby
Raw Normal View History

2022-10-11 01:57:18 +05:30
# frozen_string_literal: true
module Projects
module PagesHelper
def can_create_pages_custom_domains?(current_user, project)
current_user.can?(:update_pages, project) &&
(Gitlab.config.pages.external_http || Gitlab.config.pages.external_https) &&
project.can_create_custom_domains?
end
end
end