diff options
author | James Lopez <james@jameslopez.es> | 2016-11-18 13:00:38 +0100 |
---|---|---|
committer | James Lopez <james@jameslopez.es> | 2016-11-18 13:00:38 +0100 |
commit | f5b792e22eb7bd4ecafcd2ad3bc7a388abb36ffc (patch) | |
tree | c647334269f0d4ae414d13e77711f8279aa57697 /app | |
parent | 0aa477884c6ac3298f79f62e08e63294d81735a3 (diff) | |
download | gitlab-ce-f5b792e22eb7bd4ecafcd2ad3bc7a388abb36ffc.tar.gz |
refactored updater and updated specs
Diffstat (limited to 'app')
-rw-r--r-- | app/controllers/projects/cycle_analytics/events_controller.rb | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/app/controllers/projects/cycle_analytics/events_controller.rb b/app/controllers/projects/cycle_analytics/events_controller.rb index d5e98228ddc..13b3eec761f 100644 --- a/app/controllers/projects/cycle_analytics/events_controller.rb +++ b/app/controllers/projects/cycle_analytics/events_controller.rb @@ -4,7 +4,7 @@ module Projects include CycleAnalyticsParams before_action :authorize_read_cycle_analytics! - before_action :authorize_builds!, only: [:test, :staging] + before_action :authorize_read_build!, only: [:test, :staging] before_action :authorize_read_issue!, only: [:issue, :production] before_action :authorize_read_merge_request!, only: [:code, :review] @@ -60,14 +60,6 @@ module Projects params[:events].slice(:start_date, :branch_name) end - - def authorize_builds! - return access_denied! unless can?(current_user, :read_build, project) - end - - def authorize_read_issue! - return access_denied! unless can?(current_user, :read_issue, project) - end end end end |