summaryrefslogtreecommitdiff
path: root/app/controllers/projects/labels_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/projects/labels_controller.rb')
-rw-r--r--app/controllers/projects/labels_controller.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/controllers/projects/labels_controller.rb b/app/controllers/projects/labels_controller.rb
index 8ec2cbb41e9..14f2e372bc5 100644
--- a/app/controllers/projects/labels_controller.rb
+++ b/app/controllers/projects/labels_controller.rb
@@ -68,9 +68,10 @@ class Projects::LabelsController < Projects::ApplicationController
def generate
Gitlab::IssuesLabels.generate(@project)
- if params[:redirect] == 'issues'
+ case params[:redirect]
+ when 'issues'
redirect_to project_issues_path(@project)
- elsif params[:redirect] == 'merge_requests'
+ when 'merge_requests'
redirect_to project_merge_requests_path(@project)
else
redirect_to project_labels_path(@project)