Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/projects')
-rw-r--r--app/services/projects/autocomplete_service.rb9
1 files changed, 1 insertions, 8 deletions
diff --git a/app/services/projects/autocomplete_service.rb b/app/services/projects/autocomplete_service.rb
index 223461e88b6..015f2828921 100644
--- a/app/services/projects/autocomplete_service.rb
+++ b/app/services/projects/autocomplete_service.rb
@@ -13,14 +13,7 @@ module Projects
end
def labels
- LabelsFinder.new(current_user, project_id: project.id).execute.
- pluck(:title, :color).map { |l| { title: l.first, color: l.second } }
- end
-
- def unlabels(noteable)
- return [] unless noteable && noteable.respond_to?(:labels)
-
- noteable.labels.pluck(:title, :color).map { |l| { title: l.first, color: l.second } }
+ LabelsFinder.new(current_user, project_id: project.id).execute.select([:title, :color])
end
def commands(noteable, type)