diff options
author | Nick Thomas <nick@gitlab.com> | 2017-06-20 14:13:04 +0300 |
---|---|---|
committer | Nick Thomas <nick@gitlab.com> | 2017-06-21 12:56:45 +0300 |
commit | 8e5bf9d8dc0cc7ef683eb9bebfe7fbde79db6cf1 (patch) | |
tree | 20fe2a7fd35d9d0b29e870dfdb626bc04bfc70c3 /app/controllers/projects/issues_controller.rb | |
parent | 03228cb5b659ab6c9b631bafdf21ba77d6d2d2fa (diff) |
Use the new check_project_feature_available! method in project controllers
Diffstat (limited to 'app/controllers/projects/issues_controller.rb')
-rw-r--r-- | app/controllers/projects/issues_controller.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/projects/issues_controller.rb b/app/controllers/projects/issues_controller.rb index 56f76e752d0..dfc6baa34a4 100644 --- a/app/controllers/projects/issues_controller.rb +++ b/app/controllers/projects/issues_controller.rb @@ -9,7 +9,7 @@ class Projects::IssuesController < Projects::ApplicationController prepend_before_action :authenticate_user!, only: [:new] before_action :redirect_to_external_issue_tracker, only: [:index, :new] - before_action :module_enabled + before_action :check_issues_available! before_action :issue, except: [:index, :new, :create, :bulk_update] # Allow write(create) issue @@ -250,7 +250,7 @@ class Projects::IssuesController < Projects::ApplicationController return render_404 unless can?(current_user, :push_code, @project) && @issue.can_be_worked_on?(current_user) end - def module_enabled + def check_issues_available! return render_404 unless @project.feature_available?(:issues, current_user) && @project.default_issues_tracker? end |