From 56c95fb6a157be67c11172e16c5417bbcf168eb0 Mon Sep 17 00:00:00 2001 From: Mayra Cabrera Date: Wed, 21 Mar 2018 15:24:49 -0600 Subject: Changes ci/lints controller to use authorize before action Also includes a comment on Ci::Config regarding that's going to be override by EE --- app/controllers/projects/ci/lints_controller.rb | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'app/controllers/projects/ci') diff --git a/app/controllers/projects/ci/lints_controller.rb b/app/controllers/projects/ci/lints_controller.rb index 47328504cd5..a2185572a20 100644 --- a/app/controllers/projects/ci/lints_controller.rb +++ b/app/controllers/projects/ci/lints_controller.rb @@ -1,5 +1,5 @@ class Projects::Ci::LintsController < Projects::ApplicationController - before_action :ensure_user_access + before_action :authorize_create_pipeline! def show end @@ -24,8 +24,4 @@ class Projects::Ci::LintsController < Projects::ApplicationController def yaml_processor_options { project: @project, sha: project.repository.commit.sha } end - - def ensure_user_access - return access_denied! unless can?(current_user, :create_pipeline, @project) - end end -- cgit v1.2.1