summaryrefslogtreecommitdiff
path: root/app/controllers/projects/application_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/projects/application_controller.rb')
-rw-r--r--app/controllers/projects/application_controller.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/projects/application_controller.rb b/app/controllers/projects/application_controller.rb
index e2f81b09adc..89f1128ec36 100644
--- a/app/controllers/projects/application_controller.rb
+++ b/app/controllers/projects/application_controller.rb
@@ -89,4 +89,8 @@ class Projects::ApplicationController < ApplicationController
def builds_enabled
return render_404 unless @project.feature_available?(:builds, current_user)
end
+
+ def require_pages_enabled!
+ not_found unless Gitlab.config.pages.enabled
+ end
end