summaryrefslogtreecommitdiff
path: root/app/services/labels
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-11-13 19:20:48 +0100
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-11-16 14:07:38 +0100
commit986695e136a8f6afa326048b30be77a9265d3bf7 (patch)
tree390e60bd0213b3c431094cfe71395be845b77714 /app/services/labels
parent05335a3c8584c48a9317bd0919eccee6948de742 (diff)
downloadgitlab-ce-986695e136a8f6afa326048b30be77a9265d3bf7.tar.gz
Refactor global and group milestones logic
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/services/labels')
-rw-r--r--app/services/labels/group_service.rb26
1 files changed, 0 insertions, 26 deletions
diff --git a/app/services/labels/group_service.rb b/app/services/labels/group_service.rb
deleted file mode 100644
index b26cee24d56..00000000000
--- a/app/services/labels/group_service.rb
+++ /dev/null
@@ -1,26 +0,0 @@
-module Labels
- class GroupService < ::BaseService
- def initialize(project_labels)
- @project_labels = project_labels.group_by(&:title)
- end
-
- def execute
- build(@project_labels)
- end
-
- def label(title)
- if title
- group_label = @project_labels[title].group_by(&:title)
- build(group_label).first
- else
- nil
- end
- end
-
- private
-
- def build(label)
- label.map { |title, labels| GroupLabel.new(title, labels) }
- end
- end
-end