summaryrefslogtreecommitdiff
path: root/app/controllers/projects/pages_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/projects/pages_controller.rb')
-rw-r--r--app/controllers/projects/pages_controller.rb14
1 files changed, 10 insertions, 4 deletions
diff --git a/app/controllers/projects/pages_controller.rb b/app/controllers/projects/pages_controller.rb
index db0762a6cff..13c2a3ab750 100644
--- a/app/controllers/projects/pages_controller.rb
+++ b/app/controllers/projects/pages_controller.rb
@@ -43,9 +43,7 @@ class Projects::PagesController < Projects::ApplicationController
respond_to do |format|
format.html do
- redirect_to project_pages_path(@project),
- status: :found,
- notice: 'Pages were scheduled for removal'
+ redirect_to project_pages_path(@project), status: :found, notice: 'Pages were scheduled for removal'
end
end
end
@@ -77,7 +75,15 @@ class Projects::PagesController < Projects::ApplicationController
end
def project_params_attributes
- %i[pages_https_only]
+ attributes = %i[pages_https_only]
+
+ return attributes unless Feature.enabled?(:pages_unique_domain)
+
+ attributes + [
+ project_setting_attributes: [
+ :pages_unique_domain_enabled
+ ]
+ ]
end
end