summaryrefslogtreecommitdiff
path: root/app/controllers/autocomplete_controller.rb
diff options
context:
space:
mode:
authorLuke "Jared" Bennett <lbennett@gitlab.com>2017-08-31 09:17:23 +0100
committerLuke "Jared" Bennett <lbennett@gitlab.com>2017-08-31 09:17:23 +0100
commitf884a4bbd7ccaf448e0d998711d20497cef6ac71 (patch)
tree65c9b70b58dea175d188114ce066cd17baf12888 /app/controllers/autocomplete_controller.rb
parent32a68328d719327d26e82684cdf354ed25598416 (diff)
parent3e092caa91853afeab3bb01be10869e45c39de5d (diff)
downloadgitlab-ce-f884a4bbd7ccaf448e0d998711d20497cef6ac71.tar.gz
Merge remote-tracking branch 'origin/master' into repo-bugsrepo-bugs
Diffstat (limited to 'app/controllers/autocomplete_controller.rb')
-rw-r--r--app/controllers/autocomplete_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/autocomplete_controller.rb b/app/controllers/autocomplete_controller.rb
index 54f78fc8719..59be955599d 100644
--- a/app/controllers/autocomplete_controller.rb
+++ b/app/controllers/autocomplete_controller.rb
@@ -55,7 +55,7 @@ class AutocompleteController < ApplicationController
.limit(AWARD_EMOJI_MAX)
.where(user: current_user)
.group(:name)
- .order(count: :desc, name: :asc)
+ .order('count_all DESC, name ASC')
.count
# Transform from hash to array to guarantee json order